I created a function that downloaded .txt files from an ftp server, using .net functions.
This works fine most of the times, but I have 1 particular error.
When the file is too small (less than 250 Bytes) and it ends with an empty line, i get the error :
Fout: '.', hexadecimal value 0x00, is an invalid character. Line 1, position 1814.
The reason is that the download adds several [NUL] values at the empty line. Below you see these values at the last line.
If I copy the fourth text line onto the fifth line, no [NUL] values will be added by the download.
This is the function :
Is the adding of the [NUL] values a setting, or am I doing something wrong in the function?
I tried it on several ftp servers, all the same error, so I do not think it's a setting on the server.
This works fine most of the times, but I have 1 particular error.
When the file is too small (less than 250 Bytes) and it ends with an empty line, i get the error :
Fout: '.', hexadecimal value 0x00, is an invalid character. Line 1, position 1814.
The reason is that the download adds several [NUL] values at the empty line. Below you see these values at the last line.
If I copy the fourth text line onto the fifth line, no [NUL] values will be added by the download.
This is the function :
Is the adding of the [NUL] values a setting, or am I doing something wrong in the function?
I tried it on several ftp servers, all the same error, so I do not think it's a setting on the server.