01-17-2015 03:53 PM
01-18-2015 01:45 AM - edited 01-18-2015 01:47 AM
I'm guessing that a keyword without anything to the right of the equals sign is considered an empty string because that is exactly what it is. That is how you define an empty string. Well, to be less ambiguous, you'd have beginning and end quotation marks with nothing in between, but since quotation marks are implied, nothing to the right of the equals sign is valid for empty string. However, it is NOT valid for any kind of number. IMHO it should throw an error 19. After all, LabVIEW can't read your mind. It sees a valid string entry so it assumes it's a string and that you are reading it incorrectly.
01-19-2015 02:47 AM
But by the same logic, shouldn't a missing parameter throw an error also? That's a bigger miss in the ini-file in my book. Yet in that case it simply uses the default, nice and quiet. I'll make a suggestion out of it.
You're fully correct in how it works and handles the missing parameter, as it is, in fact, just an empty string in this case.
/Y
01-19-2015 09:23 AM - edited 01-19-2015 09:24 AM
@Yamaeda wrote:
But by the same logic, shouldn't a missing parameter throw an error also? That's a bigger miss in the ini-file in my book. Yet in that case it simply uses the default, nice and quiet. I'll make a suggestion out of it.
You're fully correct in how it works and handles the missing parameter, as it is, in fact, just an empty string in this case.
/Y
What I am saying is that it is NOT a missing parameter. No parameter implies empty string. So LabVIEW considers the ini file to be correct and your implementation incorrect - you specified the wrong datatype. I'm not sure I want a computer to start guessing user intent for this. As it stands, it does throw an error telling you something went wrong.