No increment

Hi Guys I just want to add a field like the Sales Order No like in the Sales Order Form and I want to print it as it is getting printed automatically by using NEXT function. I have created a new form and added those fields.But Im very conflicted on the Codes while using NEXT. Can someone write the Code on this and help me.

Any Help will be appreciated.

Check this code in OnInsert trigger of Sales Header table

IF “No.” = ‘’ THEN BEGIN


NoSeriesMgt.InitSeries(GetNoSeriesCode,xRec.“No. Series”,“Posting Date”,“No.”,“No. Series”);