Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations GregLocock on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

NXOpen

Status
Not open for further replies.

Kodi10

Mechanical
Mar 13, 2022
1

Hello everyone

I'm starting to use NXOpen capabilities (beginner) and I want to build dynamic library file using application Codeblocks IDE *.DLL. When I try to build a portion of code see bellow (this only beginning of all functions):

#include <iostream>
#include <conio.h>
#include <string>
#include <cstring>
#include <fstream>
#include <cstdlib>
#include <cstdio>
#include <cmath>
#include <windows.h>
#include <time.h>
#include <clocale>
#include <stdio.h>
#include <string.h>
#include <uf_ugopenint.h>
#include <uf5.h>
using namespace std;

extern "C" DllExport void ufusr( char *parm, int *returnCode, int rlen )
{

UF_initialize();

}

I receive this message with error:


obj\Debug\main.o||In function `ufusr':|
main.cpp|33|undefined reference to `UF_initialize'|
||error: ld returned 1 exit status|
||=== Build failed: 2 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===|

in addiction in compiler settings I indicate this two folder with libraries:

\UGOPEN\NXOpen\UGOPEN

Can anyone tell me what is wrong?

Thanks for all tips.
 
Replies continue below

Recommended for you

Some example code ships with NX, which might help you get started; they can be found at: C:\{your NX install folder}\UGOPEN\SampleNXOpenApplications.
More code examples can be found in the GTAC solution archive:
search for "nxopen" and filter for your language of choice to see all the examples for that language. These are supposed to be moved over to the new support site soon; some examples are there already, but I'm not sure where they hid the code samples there.

www.nxjournaling.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor