Re: CFileDialog: "My Computer" not shows drives
Yeah, the variable is just a name, but you're right, according to many
conventions the name is misnamed.
I wondered about the conversion too, but it appears OP is just using ANSI.
I wonder if something got fixed when rewriting the string (maybe some weird
char in the string that wasn't showing on the screen?)
Tom
"Giovanni Dicanio" <giovanniDOTdicanio@REMOVEMEgmail.com> wrote in message
news:%23G7Y226NKHA.220@TK2MSFTNGP02.phx.gbl...
Tom Serface ha scritto:
That's strange, but glad you got it to work :o)
That's really strange... the only difference that I can spot between
static char hFilter[] = "jpg Files (*.jpg,*.jpeg)|*.jpg;*.jpeg|All Files
(*.*)|*.*||";
and
CString hFilter = "jpg Files (*.jpg,*.jpeg)|*.jpg;*.jpeg|All Files
(*.*)|*.*||";
is that on Unicode builds CString implicitly converts the ANSI string to
Unicode using CP_ACP (i.e. system default code page).
BTW: to the OP: the 'h' prefix for a char string or CString instance is
very unusual (the 'h' is used for handles, e.g. hFile, hDC, hWnd...)
better not using any prefix than a confusing one, or using some meaningufl
prefix (like 'sz' for raw C strings, or 'str' for CString).
Giovanni