Recent

Author Topic: Indy & WinCE  (Read 2691 times)

Hafedh TRIMECHE

  • New Member
  • *
  • Posts: 32
Indy & WinCE
« on: March 17, 2016, 09:57:41 pm »
Code: Pascal  [Select][+][-]
  1. function CompareString(Locale:LCID; dwCmpFlags:DWORD; lpString1:LPCWSTR; cchCount1:longint; lpString2:LPCWSTR;cchCount2:longint):longint; external KernelDLL name 'CompareStringW';
is declared as Unicode but the Microsoft API declaration is an AnsiString one:

https://msdn.microsoft.com/en-us/library/ms904713.aspx

Link to Delphi forum: https://forums.embarcadero.com/thread.jspa?messageID=810680&#810680

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 11455
  • FPC developer.
Re: Indy & WinCE
« Reply #1 on: March 18, 2016, 11:21:24 am »
The MSDN link defines it as a TCHAR, which is a type that is 8-bit (ansichar) when compiled as -A ansi api, and 16-bit as -W wide api. 

And afaik wince is generally compiled in -W mode, but I know there are exceptions. But I can't see from that MSDN link alone what it should be.

 

TinyPortal © 2005-2018