cancel
Showing results for 
Search instead for 
Did you mean: 

Block Styler - Reset Selection Block

Pioneer
Pioneer

Hi,

 

SelectionBlk.png

 

Shown above is part of interface. I need to add multiple points and orientations. Once point and orientation are specified, 'Add' Button will add this info internally into arraylist. At this point I want 'Specify Point' to be reset i.e without any selected points.  How to do that?   Thanks in advance.

5 REPLIES

Re: Block Styler - Reset Selection Block

Solution Partner Genius Solution Partner Genius
Solution Partner Genius

Set an empty vector of object into the block.

 

Elia.

Re: Block Styler - Reset Selection Block

Siemens Phenom Siemens Phenom
Siemens Phenom

You could use a SetList block to show the contents of your array in the dialog. The dialog callbacks will take care of populating the data in the seed blocks based on which line of the list is selected or if a new on is to be created.

Re: Block Styler - Reset Selection Block

Pioneer
Pioneer
I have already tried this. the following empty vector assignment throws Nullreference exception error.  Any other way?

TaggedObject[] emptyVectors = null;
PtBlkProp.SetTaggedObjectVector("SelectedObjects", emptyVectors);

Re: Block Styler - Reset Selection Block

Esteemed Contributor
Esteemed Contributor

This is no empty array, it is a null array.

How about using:

TaggedObject[] emptyVectors = {};

In C this was creating an empty array with a memory reference, if I remember correctly, don't know about C++/C#.

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

How to Get the Most from Your Signature in the Community

Re: Block Styler - Reset Selection Block

Pioneer
Pioneer

That worked. Thanks Buddy.