Hi
I have a customer who have a chart of accounts where all accounts starts with 0.
We would like to reverse that decision, and remove all zeros.
That is, change 02010 to 2010, 02020 to 2020 and so on.
It's possible to do that field by field, but as as there is a lot og accounts, we would like to that through C/AL.
Anyone to give some directions..?
0
Answers
The account number shall be changed both on ledger table, ledger transactions and on any other tables where the original account number is.
When you type a new accountnumber i No. field, NAV askes if you want to change the accountno. - I answer yes to this. But I would like to make a programme to run thru all accounts and delete first zero in the No. field, and on all relations.
Does it make sense?
if copystr(GLAccount."No.",1,1)='0' then begin
Glaccount.rename(copystr(GLAccount."No.",2,strlen(GLAccount."No.")-1)
end;
There are two levels of accounts, the ones with are larger; they're the ones the users works with. And you've the ones which agroup the other ones; these ones are important in reporting and management roles.