• Login
Community
  • Login

New Plugin gets 'This ANSI plugin is not compatible with your Unicode Notepad++'

Scheduled Pinned Locked Moved Notepad++ & Plugin Development
6 Posts 2 Posters 4.5k Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E
    Erwin Marschalk
    last edited by Mar 21, 2018, 7:04 PM

    I’ve created a sample Plugin derived from NppPluginTemplate. Its compiled with Embarcadero’s C++ Builder as a 32 Bit application and with UNICODE. The function isUnicode() is build and exported from the DLL. But if i start Npp i get the messagebox:

    This ANSI plugin is not compatible with your Unicode Notepad++

    NppPluginDemo.dll is not compatible with the current version of Notepad++

    Npp Debug Info is:

    Notepad++ v7.5.4 (32-bit)
    Build time : Jan 1 2018 - 01:47:45
    Path : C:\Program Files (x86)\Notepad++\notepad++.exe
    Admin mode : OFF
    Local Conf mode : OFF
    OS : Windows 10 (64-bit)
    Plugins : ComparePlugin.dll DSpellCheck.dll mimeTools.dll NppConverter.dll NppExec.dll NppExport.dll NppFTP.dll NPPJSONViewer.dll NppTextFX.dll PluginManager.dll PyNPP.dll PythonScript.dll SourceCookifier.dll

    C 1 Reply Last reply Mar 21, 2018, 7:11 PM Reply Quote 1
    • C
      Claudia Frank @Erwin Marschalk
      last edited by Mar 21, 2018, 7:11 PM

      @Erwin-Marschalk said:

      isUnicode()

      not only build but returns True?

      Cheers
      Claudia

      1 Reply Last reply Reply Quote 0
      • E
        Erwin Marschalk
        last edited by Mar 21, 2018, 8:22 PM

        Yes, it returns with

        return TRUE;

        as in the sample.

        Cheers

        Erwin

        C 1 Reply Last reply Mar 21, 2018, 8:25 PM Reply Quote 1
        • C
          Claudia Frank @Erwin Marschalk
          last edited by Mar 21, 2018, 8:25 PM

          @Erwin-Marschalk

          I don’t know Embarcadero’s C++ but how does it build the dll
          with stdcall or cdecl convention?

          Cheers
          Claudia

          1 Reply Last reply Reply Quote 0
          • E
            Erwin Marschalk
            last edited by Mar 22, 2018, 8:23 AM

            Claudia,

            the entry is defined as

            extern “C” __declspec(dllexport) BOOL isUnicode()

            but as i checked the dll, its exported with an underscore.

            I’ll check the linker options to remove the underscores.

            Thanks

            Erwin

            1 Reply Last reply Reply Quote 0
            • E
              Erwin Marschalk
              last edited by Mar 22, 2018, 4:51 PM

              I have it now. I compiled the plugin template without any changes. The only thing was, the C++Builder has a project option ‘C++ Compiler/Output/Create Underscore for Symbolnames’, which is checked by default. It must be unchecked.

              Conclusion, Npp Plugins can also developed with Embarcadero’s C++ Builder.

              Erwin

              1 Reply Last reply Reply Quote 1
              2 out of 6
              • First post
                2/6
                Last post
              The Community of users of the Notepad++ text editor.
              Powered by NodeBB | Contributors