UG NX and VB.NET
UG NX and VB.NET
(OP)
I am not a UG user currently but the company is going to move onto NX soon. I was told by a sales rep in July 2003 that this coming Oct UG would announce a full API set that will work with VB.Net. Has anyone else heard anything to this effect. I am skeptical since UG still supports UNIX and thus cross-platform usage issues come up.
Thanks
Thanks
Guy Edkins
Managing Partner
Delta Group Ltd
gedkins@deltagl.com
www.deltagl.com





RE: UG NX and VB.NET
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
RE: UG NX and VB.NET
Guy Edkins
Managing Partner
Delta Group Ltd
gedkins@deltagl.com
www.deltagl.com
RE: UG NX and VB.NET
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
RE: UG NX and VB.NET
-Derek
DL Engineering Services
specializing in CAD Design Consultation Services
www.dl-engineering.com
RE: UG NX and VB.NET
tnx
RE: UG NX and VB.NET
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
RE: UG NX and VB.NET
I need to extract part attributes from PRT file somehow can you help, pls? I'm trying to do that for 3 months, and w/o success.
Tnx
RE: UG NX and VB.NET
If you are looking to get the standard properties stored in the header of the NX files you should be able to do this using dsofile.dll (free from Microsoft, just Google it) and then have VB/VBA read or write the custom properties you are after. I use it all the time. Sounds like UG better look harder at there competition (Solidworks) as the API libraries are free with the core product. Buy the product and start programming. No a la carte charges!
Guy Edkins
Managing Partner
Delta Group Ltd
gedkins@deltagl.com
www.deltagl.com
RE: UG NX and VB.NET
RE: UG NX and VB.NET
When I saw a demo of NX the engineer created a property as noted above and then opened a windows explorer and right clicked and looked at the properties and there was the newly created property. Am I missing something?
Guy
Guy Edkins
Managing Partner
Delta Group Ltd
gedkins@deltagl.com
www.deltagl.com
RE: UG NX and VB.NET
RE: UG NX and VB.NET
And they charge for the VB module? Man, UG is ripping their customers for everything they have. You get a free VB and C+ api with Solidworks. And it's macro language is vb so really you don't even need a copy of VB unless you want to run the program outside Solidworks.
Jason Capriotti
Smith & Nephew, Inc.
RE: UG NX and VB.NET
The UF command is a C call to get the internal part attributes. If you know how to wrap a C call into your VB program, you are set to go. UG on Windows requires VC6 to compile the code.
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
RE: UG NX and VB.NET
You can search the help to read the whole thing.
-------------------------------
Creating, Editing, and Viewing Part Attributes
You can create, edit, and view part attributes using a part's Properties pop-up menu on Windows Explorer. This allows you to create, view, modify, and delete part attributes without fully loading a part. You can also cut and copy part attributes from Windows Explorer and paste them to:
the Attributes page in an active Unigraphics NX session (File->Properties->Attributes)
another Unigraphics NX part
a text editor
This feature does not require an active Unigraphics NX session and works only for parts created in Unigraphics NX2 and later.
Jason Capriotti
Smith & Nephew, Inc.
RE: UG NX and VB.NET
-Derek
DL Engineering Services
specializing in CAD Design Consultation Services
www.dl-engineering.com
RE: UG NX and VB.NET
Win2000
UG NX 2.0.2.2
Jason Capriotti
Smith & Nephew, Inc.
RE: UG NX and VB.NET
I do not have anything like you described (part's Properties pop-up menu on Windows Explorer) I just cant find it did you install some new features to support it?
I do have only standard winxp file properties.
To looslib I tried to wrapp open API C func to dll and call it from VB but I cannot call it more than once because second time i get no result from that function.
RE: UG NX and VB.NET
Jason Capriotti
Smith & Nephew, Inc.
RE: UG NX and VB.NET
If I am correct about the file properties then the DSOFile.dll is the easy way to do the reading and writing of custom props. I do it all the time in Solidworks. I can mass release about 150 drawings in about 8 seconds. It all reports up to the revision block on the face of the drawing too. Hopefully I will be able to do the same in UG NX3 with VB.NET.
Guy Edkins
Managing Partner
Delta Group Ltd
gedkins@deltagl.com
www.deltagl.com
RE: UG NX and VB.NET
Maybe your SolidWorks spoiled PRT files of having Custom Properties under Windows Explorer?
Henry
RE: UG NX and VB.NET
Tough transition mind ya, but I'm getting there.
Jason Capriotti
Smith & Nephew, Inc.
RE: UG NX and VB.NET
regsvr32 "%ugii_base_dir%"\ugii\ugpropext.dll
Windows Explorer must be restarted - (logoff/login)
Part file(s) must be saved in NX2.
Uninstalling, reinstalling, relocating, or upgrading NX will not ungregister the dll. (use regsvr32 /u ...)
RE: UG NX and VB.NET
Thats on hell of fine tip.
Now does anyone know is it possible to use DSOFile.dll to read-write these attributes?
Henry
RE: UG NX and VB.NET
RE: UG NX and VB.NET
Where is this command, ugpropext.dll, documented?
Are you sharing UGS secret files that only employees know how they function? There are a few in the ugii directory if you are willing to experiment with them.
"Wildfires are dangerous, hard to control, and economically catastrophic."
Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
RE: UG NX and VB.NET
As I suggested earlier in the thread as long as the UG file format adheres to the MS header format then DSOfile will read/write the properties very nicely. It is amazing how fast it can do it too. I regularly write 400 to 500 files in just a few seconds. Keep in mind the files cannot be open by any other process if you are attempting to write via DSO. You can do error checking for that however or batch it for an off hours process.
Guy Edkins
Managing Partner
Delta Group Ltd
gedkins@deltagl.com
www.deltagl.com
RE: UG NX and VB.NET
It appears that Ben was correct in his original statement about UG Attributes being internal to UG and not passed to the windows header data. I set up my machine with UG and enabled the custom prop extension and then ran my standard DSO tool against a UG file and no luck, it does not "see" the UG "Attributes". So my automation tools won't work for now (running 2.0.2.2). With the advent of 3.0 we may see an improvement in external data management of UG. Oh well, I think got somewhat hoodwinked by the UG sales folks earlier this year with the demo they did.
Guy Edkins
Managing Partner
Delta Group Ltd
gedkins@deltagl.com
www.deltagl.com
RE: UG NX and VB.NET
I wish I had "secrets" to tell
The NX2 Beta What's New Guide was the first mention of the part attributes access in Windows explorer.
RE: UG NX and VB.NET
Cool tip.