I have a batch file that does a lot of processes. One included is reading a number from an area of the file. It looks like this:
for /f "tokens=1,2 skip=2 delims==" %%a in ('find /i "PATIENT_PREFIX" c:\RadiologyTechnologySeeMyRad_EIRMC\FILES.txt') do @set myvar11=%%b
This is not the same number nor the same number of characters, but it needs to be. So, how can I read the value as I now set it as myvar11 for later use, but i want it as myvar11 + preceding zeros to make it a 9 digit number.
4848 should be 000004848
448392 should be 000448392
1 should be 000000001
832756491 should be 832756491
I need every single number to be a 9 digit number. Precedign zeros to be included if it is shorter for whatever reason. Thoughts? I am hoping we can just have another line that somehow creates myvar12 as the number or at least the correct number of '0's and I could concatenate the two variables later.