NTK and The NTK Project
are properties of Jn Dechereux
Home | Documentation | FAQ.

Vanilla 1.1.8 is a product of Lussumo. More Information: Documentation, Community Support.

Welcome Guest!
Want to take part in these discussions? If you have an account, sign in now.
If you don't have an account, apply for one now.
    •  
      CommentAuthorwaltspon
    • CommentTimeMay 14th 2018
     
    Hello there

    I am migrating a harbour+WVW program to GUI NTK and need to convert unicode strings to Ansi and reverse. In Harbour I used win_widetoansi()/ansitowide() but can't find similar functions in xHarbour. Does anyone know a way to that in NTK or have some code to share?

    Any help would be much appreciated.
    Thanks and regards,
    Walter
    •  
      CommentAuthorAbbougaga
    • CommentTimeMay 15th 2018
     
    Just try:
    NTK_AnsiToWide(cExpression)
    NTK_WideToAnsi(cExpression)

    OR you can use Win32 APIs:
    NTK_MultiByteToWideChar(CP_ACP, 0, cExpression)
    NTK_WideCharToMultiByte(CP_ACP, 0, cExpression)

    Simple as that! See also NTKCORE_PART2.PDF

    HTH,
    Ab
    •  
      CommentAuthorwaltspon
    • CommentTimeMay 16th 2018
     
    Hi Ab
    Thanks for the reply. Both NTK_AnsiToWide/WideToAnsi() work perfectly. :)
    Walter