Menu

can't link wnsprintf?

2003-02-14
2012-09-26
  • Nobody/Anonymous

    it this my error?

     
    • Nobody/Anonymous

      From MSDN:

      Minimum DLL Version shlwapi.dll version 5.0 or later
      Custom Implementation No
      Header shlwapi.h
      Import library shlwapi.lib
      Minimum operating systems Windows 2000, Windows NT 4.0 with Internet Explorer 5, Windows 98, Windows 95 with Internet Explorer 5

      C:\MinGW\include>grep wnsprintf *
      shlwapi.h:WINSHLWAPI int __cdecl wnsprintfA(LPSTR,int,LPCSTR,...);
      shlwapi.h:WINSHLWAPI int __cdecl wnsprintfW(LPWSTR,int,LPCWSTR,...);
      shlwapi.h:#define wnsprintf wnsprintfW
      shlwapi.h:#define wnsprintf wnsprintfA

      So you have to include shlwapi.h and link libshlwapi.a to your project:

      #include <shlwapi.h>
      Project/Project Options/Compiler/Compiler Options/Linker. Add -lshlwapi 

      /Effenberg

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.