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!

UG NX and VB.NET 5

Status
Not open for further replies.

gedkins

Mechanical
May 11, 2001
45
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

Guy Edkins
Managing Partner
Delta Group Ltd

gedkins@deltagl.com
 
Replies continue below

Recommended for you

UG NX3 is suppossed to have a VB.net interface on Windows platforms only.


"Wildfires are dangerous, hard to control, and economically catastrophic."

Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
 
October 2004, the last I heard.

"Wildfires are dangerous, hard to control, and economically catastrophic."

Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
 
September 15 is the rollout date I heard for UGNX3. I am not a programmer, and know very little about vb.net or any other language of programming, but I do know that what was formerly known as a macro, will now be known as a journal, and will be formatted in vb. The script is able to be cut and pasted into vb.NET code. Ben is right, as far as I know, this is all only available on Windows.

-Derek
DL Engineering Services

specializing in CAD Design Consultation Services
 
I need same thing, I need something like UG .NET library. I try to use open C API for UG, and called one function from VB, but it did not work well. How can I get this .NET package so I'll be able to use it with VB.NET?

tnx
 
Pay the Bucks. The .net interface is an additional cost module, even if you currently have UG/Open API.

"Wildfires are dangerous, hard to control, and economically catastrophic."

Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
 
So looslib then you should probably know, what does this function (UF_ATTR_ask_part_attrs_in_file) do? I just need to rewrite it to VB that's it.
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

 
Mirdous,

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
 
Tnx a lot man, but I'm not looking for document file attributes. But atributes which you can specify in unigraphics File->Properties->Attributes (those are only string type).
 
Mirdous,

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
 
Well I dont know maybe it was different version, i'm using NX2. But those attrs u are talking about are not the one I'm looking for.
 
I tried creating File/Properties/Atributes and they do not show up in windows explorer under file properties/ custom. Is there a switch somewhere I'm missing?

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.
 
UG atributes are stored as string values internal to UG. There is no passing of these values to the Windows file property settings.

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
 
Ben, this is in the help which makes it sound like you can.
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.
 
Well now that you mension it, there is a 4th tab on my explorer properties dialog for UG parts, called "Custom". There are a bunch of attributes on there to fill out, but I cannot figure out how to customize them. BTW, I'm running WXPSP2, and have installed NX3. Not sure if that has anything to do with this page showing up.

-Derek
DL Engineering Services

specializing in CAD Design Consultation Services
 
"Custom" is there for any windows file. It's what we used for Solidworks. I don't believe you can customize the list but you can type in any name you want.

Win2000
UG NX 2.0.2.2

Jason Capriotti
Smith & Nephew, Inc.
 
Gildashard

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.
 
It's the standard windows file properties dialogue. Right click a file and select properties. Then there is a custom tab.

Jason Capriotti
Smith & Nephew, Inc.
 
Mirdous,

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
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor