<?xml version="1.0" encoding="UTF-8"?>        <rss version="2.0"
             xmlns:atom="http://www.w3.org/2005/Atom"
             xmlns:dc="http://purl.org/dc/elements/1.1/"
             xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
             xmlns:admin="http://webns.net/mvcb/"
             xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
             xmlns:content="http://purl.org/rss/1.0/modules/content/">
        <channel>
            <title>
									Acumatica Event Handlers - FieldSelecting / FieldDefaulting / FieldVerifying / FieldUpdating / FieldUpdated - Everything Else				            </title>
            <link>https://www.augforums.com/forums/everything-else/acumatica-event-handlers-fieldselecting-fielddefaulting-fieldverifying-fieldupdating-fieldupdated/</link>
            <description>Acumatica User Group Forums</description>
            <language>en-US</language>
            <lastBuildDate>Wed, 17 Jun 2026 00:01:19 +0000</lastBuildDate>
            <generator>wpForo</generator>
            <ttl>60</ttl>
							                    <item>
                        <title>RE: Acumatica Event Handlers - FieldSelecting / FieldDefaulting / FieldVerifying / FieldUpdating / FieldUpdated</title>
                        <link>https://www.augforums.com/forums/everything-else/acumatica-event-handlers-fieldselecting-fielddefaulting-fieldverifying-fieldupdating-fieldupdated/#post-11105</link>
                        <pubDate>Fri, 29 Dec 2023 21:09:01 +0000</pubDate>
                        <description><![CDATA[Thank you Yuriy. This is helpful.]]></description>
                        <content:encoded><![CDATA[<p>Thank you Yuriy. This is helpful.</p>]]></content:encoded>
						                            <category domain="https://www.augforums.com/forums/everything-else/">Everything Else</category>                        <dc:creator>Tim Rodman</dc:creator>
                        <guid isPermaLink="true">https://www.augforums.com/forums/everything-else/acumatica-event-handlers-fieldselecting-fielddefaulting-fieldverifying-fieldupdating-fieldupdated/#post-11105</guid>
                    </item>
				                    <item>
                        <title>RE: Acumatica Event Handlers - FieldSelecting / FieldDefaulting / FieldVerifying / FieldUpdating / FieldUpdated</title>
                        <link>https://www.augforums.com/forums/everything-else/acumatica-event-handlers-fieldselecting-fielddefaulting-fieldverifying-fieldupdating-fieldupdated/#post-11089</link>
                        <pubDate>Fri, 22 Dec 2023 16:56:01 +0000</pubDate>
                        <description><![CDATA[In order to find out, I want to give my viewpoint.
FieldUpdated is executed after the field is changed in the cache. FieldUpdating is triggered before the value of the field is set.
As out...]]></description>
                        <content:encoded><![CDATA[<p></p>
<p>why there are two Events (FieldUpdating and FieldUpdated) instead of one.</p>
<p></p>
<p>In order to find out, I want to give my viewpoint.</p>
<p>FieldUpdated is executed after the field is changed in the cache. FieldUpdating is triggered before the value of the field is set.</p>
<p>As outcome, FieldUpdated gives me, as a developer mechanism to react on event when field is changed. Examples:</p>
<p>1. If value is zero, execute one logic</p>
<p>2. If value is greater then zero execute another logic</p>
<p>3. If value is negative, execute another logic.</p>
<p>FieldUpdating allows me to execute some logic before some value is set and potentially prevent from setting value to something, that goes against business logic. Sometimes developer may use FieldUpdating in a wrong way ( i.e. Validation logic, for this purpose should be used FieldVerifying ), but most common scenario is if such and such field is going to receive value, trigger some other changes. Another example of FieldUpdating usage is assigning default value, formatting or converting.</p>
<p>I do admit, that it is kind of slight difference, and there are plenty of use cases when these events may be used instead of each other withouth difference. And I'm bet there are a lot of cases when it is used. </p>
<p>To put simply: FieldUpdating is about preparing and validating the new value, while FieldUpdated is about reaction on the change that already occured.</p>]]></content:encoded>
						                            <category domain="https://www.augforums.com/forums/everything-else/">Everything Else</category>                        <dc:creator>Juriy Zaletsky</dc:creator>
                        <guid isPermaLink="true">https://www.augforums.com/forums/everything-else/acumatica-event-handlers-fieldselecting-fielddefaulting-fieldverifying-fieldupdating-fieldupdated/#post-11089</guid>
                    </item>
				                    <item>
                        <title>Acumatica Event Handlers - FieldSelecting / FieldDefaulting / FieldVerifying / FieldUpdating / FieldUpdated</title>
                        <link>https://www.augforums.com/forums/everything-else/acumatica-event-handlers-fieldselecting-fielddefaulting-fieldverifying-fieldupdating-fieldupdated/#post-4175</link>
                        <pubDate>Thu, 02 May 2019 19:20:33 +0000</pubDate>
                        <description><![CDATA[Regarding the following Acumatica Event Handlers:1. FieldSelecting2. FieldDefaulting3. FieldVerifying4. FieldUpdating5. FieldUpdatedI&#039;m taking some notes for myself here so I can refer back ...]]></description>
                        <content:encoded><![CDATA[<p>Regarding the following Acumatica Event Handlers:</p><p>1. FieldSelecting<br />2. FieldDefaulting<br />3. FieldVerifying<br />4. FieldUpdating<br />5. FieldUpdated</p><p>I'm taking some notes for myself here so I can refer back to them in the future.</p><p>I am NOT a developer and I still refuse to work in Visual Studio. It's too complicated for me. But I can do some light coding stuff through the Acumatica <span style="text-decoration: underline">Customization Projects (SM204505)</span> screen in my web browser. There are a lot of options that you can set there. Especially interesting is the <span style="text-decoration: underline">EVENTS</span> tab that you see when you click on a field:</p><p><img src="https://i.imgur.com/4aSaG1i.png" /></p><p>All of those Event are specific to the field that you clicked on. In my screenshot above, I clicked on the <span style="text-decoration: underline">Alternate ID</span> field. But you can override the behavior of an Event by highlighting the Event (I did <span style="text-decoration: underline">FieldSelecting</span> in the screenshot above) and clicking the <span style="text-decoration: underline">ADD HANDLER</span> drop-down which gives you two options: <span style="text-decoration: underline">Keep Base Method</span> and <span style="text-decoration: underline">Override Base Method</span>.</p><p> </p><p>If you select <span style="text-decoration: underline">Keep Base Method</span>, then Acumatica will generate something in the <span style="text-decoration: underline">CODE</span> area of your Customization Project that looks like this:</p><p><img src="https://i.imgur.com/OG4m2dT.png" /></p><p> </p><p>If you select <span style="text-decoration: underline">Override Base Method</span>, then Acumatica will generate something in the <span style="text-decoration: underline">CODE</span> area of your Customization Project that looks like this:</p><p><img src="https://i.imgur.com/UN84HR1.png" /></p><p> </p><p>You can see that the two screenshots above are similar, but not the same. Despite the names, I think they actually do the opposite of what they say. As far as I can tell, the <span style="text-decoration: underline">Keep Base Method</span> code will replace what Acumatica normally does with whatever code you want and <span style="text-decoration: underline">Override Base Method</span> code will add extra stuff to what Acumatica normally does. At least that's how I think it works, the opposite of what the names imply.</p><p>Then it becomes a question of which Event you want to modify. That's where we come back to this list:</p><p>1. FieldSelecting<br />2. FieldDefaulting<br />3. FieldVerifying<br />4. FieldUpdating<br />5. FieldUpdated</p><p>When does each one get used?</p><p>I did some digging in the Acumatica help and am summarizing my notes here.</p><p>What Events get executed and what order they get executed in depends on what you're doing with a record on the screen. This is what it says in the Help:</p><p>1. Update - FieldUpdating -&gt; FieldVerifying -&gt; FieldUpdated<br />2. Insert - FieldDefaulting -&gt; FieldUpdating -&gt; FieldVerifying -&gt; FieldUpdated<br />3. Delete - FieldUpdating -&gt; FieldUpdated<br />4. Display - FieldSelecting</p><p>And there is a nice diagram which you find here:</p><p><strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=d9cf6274-f5c8-43e7-9d13-9b423113d67e" target="true">https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=d9cf6274-f5c8-43e7-9d13-9b423113d67e</a></strong></p><p><img src="https://i.imgur.com/4IXyvvk.png" /></p><p>What complicates things is the <span style="text-decoration: underline">Attribute</span> on the field which, as far as I understand it, are more related to the Field DAC (Data Access Class) than they are to the Screen. The Attribute has its own Event Handlers associated with it. Sometimes it gets called before the Field Event, sometimes after, or sometimes not at all if you set Cancel to true. The Attribute still makes my head hurt and I don't want to take notes on it here, but here are the help articles with the details of when the Attribute Event Handlers get called for future reference:</p><p><strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=8f77ddc6-374b-4ad9-be20-a282febf88f8" target="true">1. Update - Gory Details</a></strong><br /><strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=5fb67bf3-6db4-498d-983c-e4fe28a65d11" target="true">2. Insert - Gory Details</a></strong><br /><strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=0d160007-252e-44f8-a9cd-25b40b786dc1" target="true">3. Delete - Gory Details</a></strong><br /><strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=02e8c036-30e7-4cca-86bd-b0dc47626793" target="true">4. Display - Gory Details</a></strong></p><p> </p><p>What I'm wondering right now is why there are two Events (FieldUpdating and FieldUpdated) instead of one. Hmmm, not sure yet.</p><p>In the two code screenshots above, there is something called PXFieldSelectingEventArgs. You can use that to reference some useful things.</p><p>What you can reference with PXFieldSelectingEventArgs depends on what Event Handler you're using.</p><p>1. FieldSelecting - ExternalCall, IsAltered, ReturnState, ReturnValue, Row <strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=2f8b55bc-7cb1-4f43-36f5-922c834d5b84" target="true" rel="nofollow">(click here for more info)</a></strong><br />2. FieldDefaulting - NewValue, Row <strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=4c120fa1-21a5-0ca2-7e8b-7594527ce4e6" target="true" rel="nofollow">(click here for more info)</a></strong><br />3. FieldVerifying - ExternalCall, NewValue, Row <strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=d7584c2d-215c-8273-5d14-779218e5e581" target="true" rel="nofollow">(click here for more info)</a></strong><br />4. FieldUpdating - NewValue, Row <strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=90b1942d-b3e5-209d-9ced-dd928061438f" target="true" rel="nofollow">(click here for more info)</a></strong><br />5. FieldUpdated - ExternalCall, OldValue, Row <strong><a href="https://help-2018r2.acumatica.com/Help?ScreenId=ShowWiki&amp;pageid=2a3deef7-bc1f-ed63-eb22-452201c9c2b0" target="true" rel="nofollow">(click here for more info)</a></strong></p>]]></content:encoded>
						                            <category domain="https://www.augforums.com/forums/everything-else/">Everything Else</category>                        <dc:creator>Tim Rodman</dc:creator>
                        <guid isPermaLink="true">https://www.augforums.com/forums/everything-else/acumatica-event-handlers-fieldselecting-fielddefaulting-fieldverifying-fieldupdating-fieldupdated/#post-4175</guid>
                    </item>
							        </channel>
        </rss>
		