Announcement

Collapse
No announcement yet.

compilierungsfehler

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • compilierungsfehler

    ich habe angefangen mit ADS zwischen c++ und sps in visual studio 2008 zu programieren.
    jetzt mache ich beispiele, die ich bei beckhoff eins zu eins abgechrieben habe. bei der Ausführung
    der code bekomme ich folgende fehler
    Build log was saved at "file://c:\Documents and Settings\nam1fe\My Documents\Visual Studio 2008\Projects\DLL-Version auslesen\DLL-Version auslesen\Debug\BuildLog.htm"
    1>DLL-Version auslesen - 1 error(s), 0 warning(s)
    ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
    kann jemand mir helfen?

  • #2
    Wer soll ohne Code und Fehler etwas dazu sagen? Du hast in das Log geschaut?
    Zuletzt editiert von Christian Marquardt; 19.06.2012, 10:10.
    Christian

    Comment


    • #3
      Hier ist meine code
      [highlight=c++]#include <iostream>
      #include <conio.h>
      #include <windows.h>

      // ADS headers for TwinCAT2
      #include "C:\TwinCAT\ADS Api\TcAdsDll\Include\TcAdsDef.h"
      #include "C:\TwinCAT\ADS Api\TcAdsDll\Include\TcAdsApi.h"

      // ADS headers for TwinCAT3
      // #include "C:\TwinCAT3\AdsApi\TcAdsDll\Include\TcAdsDef. h"
      // #include "C:\TwinCAT3\AdsApi\TcAdsDll\Include\TcAdsAPI. h"

      void main()
      {
      long nTemp;
      AdsVersion* pDLLVersion;

      nTemp = AdsGetDllVersion();
      pDLLVersion = (AdsVersion *)&nTemp;
      cout << "Version: " << (int)pDLLVersion->version << '\n';
      cout << "Revision: " << (int)pDLLVersion->revision << '\n';
      cout << "Build: " << pDLLVersion->build << '\n';
      cout.flush();
      getch();
      }[/highlight]

      Comment


      • #4
        Und der Fehler? Die zusätzlichen *.h http://infosys.beckhoff.com/italiano...mple01.htm&id= hast du eingefügt?
        Christian

        Comment

        Working...
        X