Dear all,
Can u explain me about the CurrRec and Rec Variable. I already looked on the help, but it didn't give me any information. Does this thing Hardcoded by Navision? Cause when I read about ClearAll Function, it says that it won't clear the Rec variable.
TIA
0
Comments
On a form it is the record the user is viewing.
So CurrRec is the record I see on screen. SO does the Rec?
Where have you seen this?
I was refering to Rec.
Help remarks for this is
You learn something new every day.
I can't see the need for it to be honest.
Just use a Record variable to work on a Table.
Setting the TableNo property actually adds a VAR Rec : Record ... parameter to the OnRun trigger. No more magic is involved, no CurrRec variable is accessible.
Codeunit_variable.RUN or CODEUNIT.RUN(ID) can be used with or without the property set. If the property is set you must use the Record parameter, if not you must not. Depending on which variation you use you'll get a compile time error or a run time error if you do it wrong.
Furthermore, don't look for the value "Undefined" in the lookup, nor try to type it in yourself. There is no such value accepted. Instead, don't define the property, or clear it's value to make it undefined.