|
Ok. There's my c:\printers.ini file: [Printers] Printer1=andry,mark,gwen,nick Printer2=raman,helen,dave Printer3=wendy,mavis,nicole
I ran the following code: Break On ?@STARTDIR ?@SCRIPTexe ?@KIX ?@SCRIPTDIR $ini='c:\printer.ini' $printers=split(readprofilestring($ini,'Printers',''),chr(10)) for each $printer in $printers $users=split(readprofilestring($ini,'Printers',$printer), ',') if ascan($users,@USERID)+1 ? @USERID+' gets printer '+$printer EndIf Next Sleep 1000
=========== I used the macros to give you some ideas about kixtart version etc. My USERID is andry
The Output I get from the script above is: C:\Program Files\PrimalScript\andry\Scripts KIX32.EXE 4.22 C:\Program Files\PrimalScript\andry\Scripts In other words, it just prints the macroses and then goes to the SLEEP statemnt. I've traced the script and it appears that $users array is never built properly that's why it cannot find my userid in the $users array.
Thanks for spending your time on my issue.
|