PocketMatrix forums

A read-only archive of the PocketMatrix forums (2001–2014). Posting and accounts are closed.

Linker errors with unicode

Hi

I have already used GapiDraw in Visual Studio 6 for some time with no problems, but now I came to a problem while dealing with Unicode.

Instead of using ASCII strings and then converting to unicode so they could be used, I now #defined UNICODE and _UNICODE, and changed everything to TCHARs.

The compiling gives no errors, but the linker says things like this:

error LNK2019: unresolved external symbol "__declspec(dllimport) public: long __thiscall CGapiSurface::CreateSurface(unsigned long,unsigned short const *)" (__imp_?CreateSurface@CGapiSurface@@QAEJKPBG@Z) referenced in function "long __cdecl safeLoadImage(class CGapiSurface *,unsigned short *)" (?safeLoadImage@@YAJPAVCGapiSurface@@PAG@Z)

Could anyone give me some help with this?
I tried that also, but the GapiDraw for Windows dll isn't compiled with Unicode. I guess it is done for Windows 95 compatibility.

Maurice
Any chance of releasing a version for XP for unicode? Obviously for the pocketpc its working in unicode so hopefully it wouldn't be much work?
I'd hoped to be able to have a 2D version for the pc as well, but without unicode I'd be out of luck.

Thanks much,

-David
I'll see what I can do...
cottrelld · 01 Aug 2003, 19:40 UTC — in the update?
Hi.

Did a unicode version make it into the newest update? Thanks!

-David
Hi,

Unfortunately not.. It's still on my todo-list though.. :)

//Johan
Daniel Webb · 07 Aug 2003, 14:07 UTC — When You're ready...
Just adding my weight behind the unicode for XP movement. Thanks.
Jon Wiesman · 21 Nov 2003, 00:38 UTC — Yes! Unicode version for XP! Please!
This would be really helpful to us as well.
Um. Ok.. So how do I create a Unicode target in VC 6 then? I tried simply defining _UNICODE but it didn't work... Any pointers in the right direction?
Don't know about VC6 anymore but in VC.NET you set the 'Character Set' to Unicode in the General property page of your project's config dialog.


Maurice
Not as easy in VC6 I'm afraid.. Simply changing the preprocessor defines from mbcs to _unicode didn't do the trick either.
InexorableTash · 24 Nov 2003, 17:47 UTC
Define both UNICODE (used by Win32) and _UNICODE (used by CRT). Check the VC6 output to make sure there isn't an MBCS definition sneaking in anywhere.
Thanks...
Cool, it worked.. I didn't know both UNICODE and _UNICODE was needed.. Thanks, the next release will have a unicode build for Windows 2000/XP.