On the sales order form, i have created a checkbox and a string field. The requirement is that, a number sequence has to be generated in the string field when i check the checkbox.
Any kind of help would be greatly appreciated.
Something like this:
If(checkbox.checked==true)
myField = numberSeq.num();
I’m not sure what your problem is, nevertheless MSDN: Number Sequence Framework [AX 2012] might help you. It shows both how to create a new number sequence and how to use NumberSeqFormHandler class in forms.
That link is basically for creation of Number Sequence.
The requirement for me is something different.
On the sales order form , i have a checkbox (say MyCheckBox). I also have an empty textbox (a string field).
When i check the checkbox, i want my number sequence to populate in the textbox.
Something like this:
If(checkbox.checked==true)
myField = numberSeq.num();
I am new to AX and not quite sure where and how to write this piece of code.
I hope i am clear now.
You said that before, but you didn’t explain why you can’t create a number sequence and use NumberSeqFormHandler class, as explained in the link. I would expect that the only thing you need to add is an if statement.
But maybe you have some extra requirements that yao forgot to explain.
Thanks Martin. As you said, just an if statement worked.