admin 发表于 2013-10-21 21:36:19

UG NX二次开发的Visual Studio 的配置方式

1. Open Microsoft Visual Studio.
2. Create a new VC++ project using the NX Open AppWizard.
       Create new project as:
      2.1 File->New->Project.
      2.2 Select VC++ Project using the NX Open AppWizard, DLL Library Application,
            Enter name as ExecuteCheckerAndGetResults. Click Next.
      2.3 Under Application Settings, select 'An Internal application that can be
            activated from an NX session (DLL)'.
      2.4 Select C++ for What language would you like to use in the generated
            source files. Click Finish.
    3. Add the ExecuteCheckerAndGetResults.cpp to the project by selecting the Project
       pull down and select "Add Existing Item...". Select the file using the popup window.
    4. Right-click this project in the Solution Explorer and select Properties on the popup menu.
       On the Property Pages dialog, click Configuration Manager... button to open Configuration Manager dialog.
       Select x64 for Active solution platform in the Configuration Manager when use 64 bit NX. Click Close button.
      
       Click Configuration Properties->C/C++->General to confirm $(UGII_BASE_DIR)\ugopen is existing in Additional
       Include Directories.
      
       Click Configuration Properties->Linker->General to confirm $(UGII_BASE_DIR)\ugopen is existing in Additional
       Library Directories.
      
       Click Configuration Properties->Linker->Input to confirm libnxopencpp.lib;libnxopencpp_validate.lib are
       existing in Additional Dependencies.
       Click OK button to close Configuration Manager dialog.


    5. Build the internal image by going to the Build menu and selecting either "Build Solution" or "Rebuild Solution".
    This will create an executable called ExecuteCheckerAndGetResults.dll in the Debug directory.

页: [1]
查看完整版本: UG NX二次开发的Visual Studio 的配置方式