|
-
March 7th, 2009, 02:44 AM
#1
How to search for files in a directory and subdirectorie
The following question is asked in regards to the following FAQ:
I got an error on the following line of code:
hFile = ::FindFirstFile(strPattern.c_str(), &FileInformation);
Error 4 error C2664: 'FindFirstFileW' : cannot convert parameter 1 from 'const char *' to 'LPCWSTR'
I think it's a Unicode error but i don't know how to resolve it!!!
Last edited by Andreas Masur; March 7th, 2009 at 11:42 AM.
-
March 7th, 2009, 11:43 AM
#2
Re: How to search for files in a directory and subdirectorie
The FAQ is not unicode-aware...thus in your case...you need to use 'std::wstring' instead of 'std::string'.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|