web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Unanswered

Orig method not working

(0) ShareShare
ReportReport
Posted on by

I have used two temporary tables in my form. One is for all the controls and the other is for a grid. I am trying to obtain the values before update for on of the grid fields using orig but it does not seem to be working. The same if applied on the other temp table is working fine, therefore, I am a little confused as to what to do? Could you give me a few suggestions? 

//modified method on the formdatasource field 
public void modified()
{
    real oldVal = TempTable2.orig() 
    ///using the name of the table as is because
    it has the same meaning as using cursor.///
    real newVal = TempTable2.Value; //New value, after update
}

  • WillWU Profile Picture
    22,363 on at

    Hi Shravyad,

    Could you provide the complete code?

    The orig method is generally used to compare buffers(before update),where do you use it?

  • Community Member Profile Picture
    on at

    I am trying to compare buffers as well. To find the difference in value for one field. I am using it in the form in the modified method of the datafield

  • WillWU Profile Picture
    22,363 on at

    Hi ShravyaD,

    Did you put the method before super()?

  • Community Member Profile Picture
    on at

    Hey Will,

    Yes, I did

    Shravya

  • WillWU Profile Picture
    22,363 on at

    Hi ShravyaD,

    Try to add your field after the method:

    TempTable2.orig().yourfield;

  • Community Member Profile Picture
    on at

    I tried that too but it is still not working

  • WillWU Profile Picture
    22,363 on at

    Hi ShravyaD,

    What do you mean by "not working"?

    Can you get any value or not?

  • Community Member Profile Picture
    on at

    I do not get any value. It always returns null.

    Regards,

    Shravya

  • Sergei Minozhenko Profile Picture
    23,099 on at

    Hi ShravyaD,

    Do you modify field for new record or existing one?

  • Abigail Profile Picture
    552 on at

    You would just put a pre-event handler on the table update method, then use Orig method.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 264 Super User 2026 Season 2

#2
Aayush Tiwari Profile Picture

Aayush Tiwari 219

#3
Subra Profile Picture

Subra 164 Super User 2026 Season 2

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans