學術專區 關於NI NI活動訊息 NI Developer Zone 技術支援服務 使用者解決方案 產品與服務 連絡NI MyNI
1 ratings:
 5 out of 5     Rate this Document

使用NI-DAQ Visual C++ 範例程式時(nidaqex.h)出現錯誤

主要軟體: Driver Software>>NI-DAQ
主要軟體版本: 7.0
主要軟體修正版本:
次要軟體: Measurement Studio>>Visual C++ Support

問題: 在Visual C++底下嚐試編譯並執行資料擷取範例時會出現錯誤訊息"Fatal error C1083: Cannot open include file: 'nidaqex.h': No such file or directory."


解答: 會出現此錯誤訊息的原因,是由由系統(utility)檔案與函式(function)是不允許的,有兩個可能的原因:
  1. NI-DAQ並未安裝到此電腦上。
  2. 安裝NI-DAQ時並未勾選支援其他編譯器的選項。其他編譯器包含Visual C++和Borland C++。
NI-DAQ提供所有National Instruments資料擷取卡產品的驅動程式。檔案nidaqex.h, nidaqex.lib 和 nidex32.dll 是使用範例程式前務必安裝的系統函式(utility functions)。這檔案只有在電腦已安裝其他編譯器的情形下才會安裝,如果你沒有nidex32.dll 時你必須在裝NI-DAQ時勾選此選項。在大多數的作業系統中,您可以修改您的安裝元件而不需要重新安裝。以下是系統函式(utility functions)的介紹和定義這些函式的原始檔案(source files):
  • NIDAQDelay
  • NIDAQErrorHandler
  • NIDAQMakeBuffer
  • NIDAQMean
  • NIDAQPlotWaveform
  • NIDAQWaitForKey
  • NIDAQYield
對於 LabWindows/CVI, 這些被放值在一個名為NIDAQEX.C的source code裡。

對於其他Windows 32-bit 程式語言,這些被放置在NIDEX32.DLL。通常一個static import library會包含在Windows NI-DAQ的LIB目錄底下.

To use these functions withYou must include
LabWindows/CVIthe NIDAQEX.H header file and the NIDAQEX.C file in your project
32-bit Visual C++the NIDAQEX.H header file and link in the NIDEX32.LIB import libraryTo link a library in VC++, go to Project >> Settings , and select the Link tab. Add the library name to Object/library modules.
32-bit Borland C++the NIDAQEX.H header file and link in the NIDEX32B.LIB import library
32-bit Visual Basicthe NIDEX32.BAS file in your project



相關連結:

附加檔案:





報告日期: 03/10/2003
最後更新: 03/28/2005
文件偏號: 2V9F4Q6I

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
  1 2 3 4 5
Please Contact NI for all product and support inquiries.submit