I require a script that simply generates the next highest four digit number that hasn't already been used. They will be used as account numbers in MYOB accounting software so it must be able to put a zero in front which is the only complication. e.g.
The number will be produced when windows + a is pressed. It could 'come out of' the cursor automatically or when pasted in.
That number will also be added to a data file of numbers which have already been used.
The file must be independently editable using a program such as MS excel or notepad so I can correct errors and start reusing dormant account number if I need to. The data file is to be called ACCOUNTS and I will give you the directory of where kept.
So, if the data file contained the numbers
Then the script would give me 0004 when I press windows + a and would also add 0004 to the list of numbers already used. Then the next time I pressed windows + a it would give me 0006 at the cursor and so on.
I have attached the text file that MYOB software produce. This file has five digit numbers but I don't want the first digit (the 2) to be produced at the cursor, I only want the last four digits produced.
So, if the data file was:
the script would still give me 0004 at the cursor or when I paste
I don't want anything that requires the .net framework to be installed. Aside from that, you can use whatever will work.