I created a number sequence in the form using numberSeq class in ax 2012 r3.
It is creating number sequence perfectly.
But the problem raised after deleting the record without saving the record.i.e., pressing the Esc Key.
After that creating a new record generates new number rather than the deleted number.
Eg :1. CTRL+N => record “001” is created
Delete “001” without saving using (Esc key).
CTRL+N => record “002” is created
But I want to generate 001 only.
Below is the code for generating
numSeqCode = EcoResCategory::find(recid).USMFNumberSequenceCode;
num = NumberSeq::newGetNumFromCode(numSeqCode); // Parameters Table
itemid = num.num();
Please help me!!!
Thanks in advance