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. using dumpcpp to generated files of mstscax.dll for rdp
Forum Updated to NodeBB v4.3 + New Features

using dumpcpp to generated files of mstscax.dll for rdp

Scheduled Pinned Locked Moved General and Desktop
dumpcpp mstscax
8 Posts 3 Posters 3.5k Views 2 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.
  • L Offline
    L Offline
    libin
    wrote on last edited by SGaist
    #1

    hi.
    i want to write rdp application in qt project. i use dumpcpp to generated files of mstscax.dll. after that i include the .h file and .cpp file, but when i build the project, i get the errors:
    LNK2019 unresolved external sysmbol. how to solve this problem ?

    .pro file of my project:

     QT       += core gui axcontainer
    greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
    TARGET = test
    TEMPLATE = app
    #TYPELIBS =$$system(dumpcpp $$PWD/rdp/mstscax.dll -o mstscax)
    TYPELIBS =$$PWD/rdp/mstscax.dll
    SOURCES += main.cpp\
            mainwindow.cpp \
            mstscax.cpp
    
    HEADERS  += mainwindow.h \
                mstscax.h
    
    FORMS    += mainwindow.ui
    

    [edit: added missing coding tags ``` SGaist]

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi and welcome to devnet,

      When symbols are missing it means that you are not linking to everything you need. What symbols are missing ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      L 2 Replies Last reply
      0
      • L Offline
        L Offline
        libin
        wrote on last edited by
        #3

        hi,thanks for your reply.
        my errors is:
        mainwindow.obj : error LNK2019: 无法解析的外部符号 "public: void __thiscall MSTSCLib::MsRdpClient6NotSafeForScripting::Connect(void)" (?Connect@MsRdpClient6NotSafeForScripting@MSTSCLib@@QAEXXZ),该符号在函数 "public: __thiscall MainWindow::MainWindow(class QWidget *)" (??0MainWindow@@QAE@PAVQWidget@@@Z) 中被引用
        mainwindow.obj : error LNK2019: 无法解析的外部符号 "public: void __thiscall MSTSCLib::IMsRdpClientAdvancedSettings5::SetClearTextPassword(class QString const &)" (?SetClearTextPassword@IMsRdpClientAdvancedSettings5@MSTSCLib@@QAEXABVQString@@@Z),该符号在函数 "public: __thiscall MainWindow::MainWindow(class QWidget *)" (??0MainWindow@@QAE@PAVQWidget@@@Z) 中被引用
        mainwindow.obj : error LNK2019: 无法解析的外部符号 "public: class MSTSCLib::IMsRdpClientAdvancedSettings5 * __thiscall MSTSCLib::MsRdpClient6NotSafeForScripting::AdvancedSettings6(void)const " (?AdvancedSettings6@MsRdpClient6NotSafeForScripting@MSTSCLib@@QBEPAVIMsRdpClientAdvancedSettings5@2@XZ),该符号在函数 "public: __thiscall MainWindow::MainWindow(class QWidget *)" (??0MainWindow@@QAE@PAVQWidget@@@Z) 中被引用
        mainwindow.obj : error LNK2019: 无法解析的外部符号 "public: void __thiscall MSTSCLib::MsRdpClient6NotSafeForScripting::SetServer(class QString const &)" (?SetServer@MsRdpClient6NotSafeForScripting@MSTSCLib@@QAEXABVQString@@@Z),该符号在函数 "public: __thiscall MainWindow::MainWindow(class QWidget *)" (??0MainWindow@@QAE@PAVQWidget@@@Z) 中被引用
        mainwindow.obj : error LNK2019: 无法解析的外部符号 "public: void __thiscall MSTSCLib::MsRdpClient6NotSafeForScripting::SetUserName(class QString const &)" (?SetUserName@MsRdpClient6NotSafeForScripting@MSTSCLib@@QAEXABVQString@@@Z),该符号在函数 "public: __thiscall MainWindow::MainWindow(class QWidget *)" (??0MainWindow@@QAE@PAVQWidget@@@Z) 中被引用
        debug\test.exe : fatal error LNK1120: 5 个无法解析的外部命令

        "无法解析的外部符号" is for unresolved external symbols in chinese.

        all functions used are here:
        MainWindow::MainWindow(QWidget *parent) :
        QMainWindow(parent),
        ui(new Ui::MainWindow)
        {
        ui->setupUi(this);
        //rdpWidget=new MSTSCLib::MsRdpClient6(this);
        //vBox=new QVBoxLayout(this);
        rdpWidget=new MsRdpClient6NotSafeForScripting(this);
        rdpWidget->show();
        //vBox->addWidget(rdpWidget);
        rdpWidget->SetUserName("username");
        rdpWidget->SetServer("ip");
        rdpWidget->AdvancedSettings6()->SetClearTextPassword("123");
        rdpWidget->Connect();

        }

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          The question might be silly but did you check that everything is built correctly ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • hskoglundH Offline
            hskoglundH Offline
            hskoglund
            wrote on last edited by hskoglund
            #5

            Hi, the reason you get Link errors is because those methods are not callable that way, instead, you have to use COM.
            Qt has very good support for using COM, easiest is to first test with a QAxWidget:

            Go to the designer and add a QAxWidget (if you haven't done so already).
            Double click on it to get the dialog box "Select ActiveX control".
            Select "Microsoft Terminal Services Client Control - version 1" and click OK.
            (Also you need to include axcontainer in your .pro file but I see that you have already done that.)

            Now you can set/get the properties, either in the designer or with C++ code like this:
            ui->axWidget->setProperty("Server","ip");
            qDebug() << ui->axWidget->property("Server");

            To connect:
            ui->axWidget->dynamicCall("Connect()");

            Now you should see your server in the widget's window, good luck!

            L 1 Reply Last reply
            0
            • hskoglundH hskoglund

              Hi, the reason you get Link errors is because those methods are not callable that way, instead, you have to use COM.
              Qt has very good support for using COM, easiest is to first test with a QAxWidget:

              Go to the designer and add a QAxWidget (if you haven't done so already).
              Double click on it to get the dialog box "Select ActiveX control".
              Select "Microsoft Terminal Services Client Control - version 1" and click OK.
              (Also you need to include axcontainer in your .pro file but I see that you have already done that.)

              Now you can set/get the properties, either in the designer or with C++ code like this:
              ui->axWidget->setProperty("Server","ip");
              qDebug() << ui->axWidget->property("Server");

              To connect:
              ui->axWidget->dynamicCall("Connect()");

              Now you should see your server in the widget's window, good luck!

              L Offline
              L Offline
              libin
              wrote on last edited by
              #6

              @hskoglund thanks. i understand using com object and i have implemented that way. but in that way, i think not all functions can be used. this website rdp in qt illustrates how to realize in qt. i think the reason why my project is not correct is the wrong configuration, but i dont know how to solve it.

              1 Reply Last reply
              0
              • SGaistS SGaist

                Hi and welcome to devnet,

                When symbols are missing it means that you are not linking to everything you need. What symbols are missing ?

                L Offline
                L Offline
                libin
                wrote on last edited by
                #7

                @SGaist thanks, all functions in my .h file have been implemented. may be it is not the problem of symbols. thanks anyway. if it is convenient for you, i can post my source code.

                1 Reply Last reply
                0
                • SGaistS SGaist

                  Hi and welcome to devnet,

                  When symbols are missing it means that you are not linking to everything you need. What symbols are missing ?

                  L Offline
                  L Offline
                  libin
                  wrote on last edited by
                  #8

                  @SGaist i follow this website to implement it, you can check it: rdp in qt

                  1 Reply Last reply
                  0

                  • Login

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