Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

Drop Down List NX9 journal

Status
Not open for further replies.

RodoHdz

Mechanical
Jan 26, 2015
12
Hello All.

I'm trying to generate a journal that will give options to user in a drop down list form. Once and option is selected, it will generate an attribute on the part.

I'm having a hard time with the drop down list form. I really don't have too much knowledge about vb programming and I don't know where to start.

I will appreciate if any of you fellow NX users have some pointers about this topic.

Thanks in advance
 
Replies continue below

Recommended for you

Hi Cowski

I appreciate the quick response.

If I'm not mistaken, in order to use NX block styler I need a SNAP license which I don't have. So what I was trying to do is generate that code in visual studio as a .NET or windows form designer.

Thanks again!
 
This article shows how to use a windows form with an NX journal.

For a list box, you will need to add one of those controls to the form then populate the list of choices in the control properties (or you can leave them blank and collect/generate them at run time).

www.nxjournaling.com
 
Thanks for the article cowski. Let me check it out.

I will try to get something done this weekend.

 
Hi Again.

I read through the article and basically used it as a template to generate the my own journal. Also worked on the new windows form with the drop down list.

I was able to make the journal run and it seems that the windows form is working. But at the end I keep getting an error and the system won't generate the attribute (Material).

I don't have too much experience programming but I'm assuming that because I'm using a drop down list, the value obtained from the form is an "object" and it can not be read as a string in the main module. I think the error is in line 139 and 142.

I will keep working on this and I appreciate any feedback that I can get from the forum.

I have attached the vb file for reference.

Thanks in advance.

Rodo

 
 http://files.engineering.com/getfile.aspx?folder=3654faef-9640-41ac-adc9-d26876faa564&file=Material-Selection.vb
Hello Again

Just doing an update about the Journal. After hours of research I found out that I can't use MATERIAL as a title attribute since is now reserved in NX8 and above. [surprise].

I have attached the new journal which should be running fine now. May be it needs to be refined but the overall concept of what I was looking for works.

Any feedback is very much appreciate it :)
 
 http://files.engineering.com/getfile.aspx?folder=4a8dd865-8108-4db1-a3c8-06555fb7d26f&file=Material-SelectionV2.vb
> If I'm not mistaken, in order to use NX block styler I need a SNAP license.

That's not true.

To make an NX block-based dialog, you can use either Block Styler, or you can use a SNAP BlockForm. For the former, you need a Block Styler license; for the latter, you need a SNAP license.

Actually, if you have a SNAP license, displaying a dialog with a drop-down list is pretty trivial. You just call the Snap.UI.Input.GetChoice function -- essentially one line of code. There's example code in the SNAP Reference Guide. Putting the drop-down list onto a bigger dialog along with some other stuff is a bit more complicated, but still not too bad.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor