Truncated?? command line arguments

It is 10 years or more since I did any programming and there seems to have been a severe reduction of brain cells since then.

I have been trying to pass command line arguments to a simple console application but I only seem to get the first letter of each string . I am probably doing something obvious and idiotic but I have been trying to find the problem for a couple of days and its driving me crazy. Can anyone help



Answer this question

Truncated?? command line arguments

  • Keith Hill

    Thanks. That was the problem. I was being passed 2 byte characters with high order zeros which my obsolete code saw as one character strings. Fixed (more accurately avoided) by removing Unicode character setting in Project Properties.

    The world is more complicated every time I look.


  • Michal Konecny

    I think the problem can be caused by an issue related to "Unicode" encoding, accepted a number of years ago. Probably somewhere in your program Unicode strings are interpreted as Ansi ones. From Ansi point of view, a Unicode string is frequently interpreted as a string containing the first character only.

    Maybe you should show us the fragment which deals with command line


  • Truncated?? command line arguments