I am using the Input #filenum statement to read lines from a CSV file and assign them to variable names.
The line in LotusScript is as follows:
Input #filenum% var1, var2, …var22
This works OK if the line I am reading has values for all the variables, but if the line has a blank field (ie text1,text2,text4) then the statement seems to skip the blank entry and put “text4” into the feild that should be blank.
For example, if my CSV was two lines as below:
donald,duck,12345,dduck@gmail.com
mickey,mouse,,mmouse@gmail.com
and the code is:
Input #filenum% firstname, surname, phone, email
then the results would be…
Line 1
firstname = donald
surname = duck
phone = 12345
email = dduck@gmail.com
Line 2
firstname = mickey
surname = mouse
phone = mmouse@gmail.com
email = CRASH!!!
Anyone know a way round this?