Cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted

Re: Extract all handles (Journal Identifier) from drawing sheet

Pioneer
Pioneer

I can able to find out custom sysmbols but in our custom symbol there is an attributes which I want to get and update with new value. Again this symbol is also a customised symbol created using third party tool. I am not getting notes available in custom sysmbol. Here is code I am refering..

 

Dim customobj As NXOpen.Annotations.CustomSymbol = CType(disobj, NXOpen.Annotations.CustomSymbol)

If customobj.SymbolName = "19_Li_gez_Re_Spiegelb_F5_Nr" Then

Dim note1 As NXOpen.Annotations.Note = CType(customobj.FindObject("Custom Symbol Text-1"), NXOpen.Annotations.Note)

End If

 

Here I am not sure what will be "Custom Symbol Text-1" for other notes, there are multiple notes in custom symbol.

Can you provide me solution like notes where there is no need of find object only based on note name I can modify the note text.

 

Please find the screen shot of custom symbol

Re: Extract all handles (Journal Identifier) from drawing sheet

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor

For coding with NXOpen API make sure to use a source code editor with code completion, like SharpDevelop or Visual Studio, this makes coding much easier and you get the hints about how to handle the objects.

Also make sure to always have the NXOpen API reference open when coding.

In the remarks section of the CustomSymbol class there is the reference to NXOpen.Annotations.DraftingCustomSymbolBuilder, which has the ability to manipulate the custom symbols.

The builder has the method SelectText to get the note, with GetAbitraryNoteTitle you get the information about the note.

Recording a Journal of the interactive process should give you the missing pieces for the rest of this puzzle.

Stefan Pendl, Systemmanager CAx, HAIDLMAIR GmbH
Production: NX10.0.3, VERICUT 8.1, FBM, MRL 3.1.7 | TcUA 10.1 MP7 Patch 0 (10.1.7.0) | TcVis 10.1
Development: VB.NET, Tcl/Tk Testing: NX12.0 Preparing: NX12.0 | TcVis 11.4

Employees of the customers, together we are strong Smiley Wink
How to Get the Most from Your Signature in the Community
NX Customization - Best Practice Guide

Re: Extract all handles (Journal Identifier) from drawing sheet

Pioneer
Pioneer

Hello Stefan, I am not getting good support for dimention creation in NX drawing. I am new to NX so need sample code for creating the dimension automatically to views present in drawing sheets without providing any inputs like location of dimension, two edges for dimensioning etc.

 

I have tried to record journal but it gives huge code and it is difficult to understand and pickup the correct/required lines of code for dimension creation.

 

Please help me.

 

Regards,

Rupali

Re: Extract all handles (Journal Identifier) from drawing sheet

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor

Sorry, but I don't have any samples, I only check the .NET NXOpen API reference for drafting, since I am not doing any drafting customization at all.

Have you checked the solution center for a code snippet that contains the method I mentioned?

Stefan Pendl, Systemmanager CAx, HAIDLMAIR GmbH
Production: NX10.0.3, VERICUT 8.1, FBM, MRL 3.1.7 | TcUA 10.1 MP7 Patch 0 (10.1.7.0) | TcVis 10.1
Development: VB.NET, Tcl/Tk Testing: NX12.0 Preparing: NX12.0 | TcVis 11.4

Employees of the customers, together we are strong Smiley Wink
How to Get the Most from Your Signature in the Community
NX Customization - Best Practice Guide