Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. how to import .net dll libraries in project
Forum Updated to NodeBB v4.3 + New Features

how to import .net dll libraries in project

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 3 Posters 391 Views 1 Watching
  • 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 Offline
    E Offline
    emazed
    wrote on 25 Nov 2019, 15:57 last edited by
    #1

    Hi,

    i need to inlcude dll files that usually are used with Visual C++ or c++/cli or similiar, these dll comes with ".tlb" files, and i tried to include these, but i get an error. I wrote in my include.h file:

    #import "mydll.tlb" no_namespace
    

    and i got following error message:

    mydll.tlb:1:1: error: unknown type name 'MSFT'

    why can t read and import .tlb file?? Anyone has same issue?

    Ty

    1 Reply Last reply
    0
    • H Offline
      H Offline
      hskoglund
      wrote on 25 Nov 2019, 18:24 last edited by
      #2

      Hi, make sure you're using an MSVC compiler (and not the MinGW)
      Try putting the #import statement in one of your .cpp files instead of an .h file. Also try it without the no_namespace suffix

      1 Reply Last reply
      4
      • V Offline
        V Offline
        VRonin
        wrote on 26 Nov 2019, 09:42 last edited by
        #3

        Also make sure you are compiling with the /clr option on

        "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
        ~Napoleon Bonaparte

        On a crusade to banish setIndexWidget() from the holy land of Qt

        1 Reply Last reply
        2

        1/3

        25 Nov 2019, 15:57

        • Login

        • Login or register to search.
        1 out of 3
        • First post
          1/3
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved