Hi everybody
I should copy a variable value from a form to a table. Everthing works but when I insert a new record then the variable value is set back to the inital value.
Is it possible to store the variable value also during the insert process ?
Or is it only possible to store the value, when I create a new field on the table and store the value in the table befor I insert the new record ?
Please help me ?
Greetings Iwan
0
Comments
I guess you are using a global variable. I've put a field on 'Resource Card' form (or are you using table form?) I've set its 'SourceExpr' to a global variable.
Once I enter something into the new field and browse through records, value in the new field doesn't change (this is expected). It stays the same even if I insert a new record.
Is this what you are doing or did I get it wrong?
Documentation for Microsoft Navision
E/R diagrams, Workflow diagrams, UML diagrams, process diagrams
FieldInRecord := NewVariableDeclared_DisplayedOnForm;
I would suggest that you rather use the field in the table as the sourceexpression of the control in the form. Then you don't need to worry about setting the fields in you record using code.
Regards,
Gus