cancel
Showing results for 
Search instead for 
Did you mean: 

IPR catch warning

Pioneer
Pioneer

Hi All,

 

I am trying to generate a operation in NX through a dll.So if there is any kind of warning NX throws while generating the operation I want to capture that or it should not generate my operation at all in case of warning.

 

Rite now the operation gets generated even after a warning in the operation.It doesnt know that the operation has some issues.Can anyone help me how to achieve this with C# code?

 

Regards

Keerti

6 REPLIES

Re: IPR catch warning

Esteemed Contributor
Esteemed Contributor

How does your code look like?

Have you tried a Try..Catch block?

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: NX11.0 EAP, NX12.0 EAP

How to Get the Most from Your Signature in the Community

Re: IPR catch warning

Pioneer
Pioneer

Hi stefan,

 

Please open the image i have attached here in.

 

I want to access the Alerts the UG is producing (see the right most down corner of the image ).

 

So My dll should know that there is warning/alert from UG and it should not proceed further.

 

Is it possible by try catch ?I am not sure or is there a separate API to get the info.

Re: IPR catch warning

Esteemed Contributor
Esteemed Contributor

These alerts are only displayed to the user, but you could use the method Operation.AskPathExists starting with NX 10.0.1

For the gouge status you could use Operation.GougeCheckStatus starting with NX 10.0.2

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: NX11.0 EAP, NX12.0 EAP

How to Get the Most from Your Signature in the Community

Re: IPR catch warning

Pioneer
Pioneer

thanks for the prompt replied stefan.

 

to use operation.AskPathExists do I need to equate it with some boolean variable.

 

So I have operation selected with me how should I use this(operation.AskPathExists) in my code 

Re: IPR catch warning

Esteemed Contributor
Esteemed Contributor

AskPathExists is returning a Boolean and is a method of the operation class, so each operation type inherits it.

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: NX11.0 EAP, NX12.0 EAP

How to Get the Most from Your Signature in the Community

Re: IPR catch warning

Pioneer
Pioneer

Hi ,

 

I tried AskPathExists it will say yes even if the toolpath does not exists.

 

Any other ways to check if there is incomplete toolpath ?