cancel
Showing results for 
Search instead for 
Did you mean: 

Getting the sheet size of a drawing programatically

Pioneer
Pioneer

I am using NX 9.0 and need to be able to programatically read the value for the sheet size (A,B,C,D...) of a drawing. The drawing template uses the system variable W@$SH_SHEET_SIZE to display the sheet size on the drawing but I am unsure of how to read that variable or if it is even possible using VB.Net. Any help would be appreciated.

 

Regards

5 REPLIES

Re: Getting the sheet size of a drawing programatically

Siemens Phenom Siemens Phenom
Siemens Phenom

 

The DrawingSheet class has a property called "Height" and a property called "Length".  These are both doubles, and they should allow you to get the size.  Of course if you are looking for something like "A4", then you might have to do a little clever programming to convert these doubles.

 

What language are you working in?  I can check to see if we have a relevant example.

Re: Getting the sheet size of a drawing programatically

Pioneer
Pioneer

I am using VB.Net in Microsoft Visual Studio Express 2013.

Re: Getting the sheet size of a drawing programatically

Siemens Phenom Siemens Phenom
Siemens Phenom

 

See the text attachment below.

Re: Getting the sheet size of a drawing programatically

Siemens Phenom Siemens Phenom
Siemens Phenom

GAH!!!  It ate my formatting...Text file attached - just rename it with a .vb extension.

 

Sorry about that!

 

 

Re: Getting the sheet size of a drawing programatically

Pioneer
Pioneer

Thanks Steve, that worked great!