I'm using VS.NET.. has anyone else had issues with this? Have they managed to find out what the problem is?
wchar_t mbrtowc Method
wchar_t mbrtowc Method
I seem to be having an issue with this function. I wish to convert a char* to a wchar_t*, and have found that mbrtowc(...) seems to be what I want. However, when I try to compile my application when using this function, it cannot link to the method. It compiles the individual file fine but then the linker complains. I have included <wchar.h> at the top of my code but still no luck.
I'm using VS.NET.. has anyone else had issues with this? Have they managed to find out what the problem is?
I'm using VS.NET.. has anyone else had issues with this? Have they managed to find out what the problem is?
I don't know a solution for this problem, but you could go the dirty way, using Irrlichts string class:
This should also work the other way round:
Code: Select all
char* yourstring = "blablabla";
core::stringw s = yourstring;
// you can now access the wchar_t pointer with s.c_str()
Code: Select all
wchar_t* yourstring = L"blablabla";
core::stringc s = yourstring;
// you can now access the char pointer with s.c_str()