Continue to Site

Welcome to MCAD Central

Join our MCAD Central community forums, the largest resource for MCAD (Mechanical Computer-Aided Design) professionals, including files, forums, jobs, articles, calendar, and more.

how to get\set parameter of assembly?

AdeelAhmed

New member
Hi,


i am new to java and jlink.i am trying to write Asynchronous appplication that get parameters of a spacified assembly in a GUI and set that parameters in this GUI and update and reganrate the model in Pro\E .any help or code regarding this will be very helpful.


thanks
 
Hi,


As you mentioned you are very new to J-link...I would like to know do your working in real time on Asynchoronius applications? I think it is better to work on Synchnonous applications first rather than Asynchronous applications.


Coming to your problem...you are getting the paramerts avil in the assembly you would like to set the parameters in the assembly you have the API avail to Set the parameters to the model.


I am basically Toolkit guy....


With regards


Kishore
 
hi
thanks kishorev for your replay i have tried some syncronous samples
avalible with jlink.but i am facing problem in runing asynronous
samples .secondly i require a real time solution(asynronous
application )that read proengineer session and read modelandits parameters and
also set them .i have also protoolkit.any sample code for this problem
will be very helpful.
thanks once again for Kishorev
 
Hi,





You have few samples in the Pro-E load point under your installed Pro-E,Pro-Toolkit folder will be there,in side some examples are given on Asyncronous applciation,i think you are looking for J-Link,I think one Jlink folder is also avail in Pro-E loadpoint let check it you get some sample on your req't.





Kishore V
 
Hi,



i only wrote synchronous applications!



There u can get an Parameter:

Code:
Parameter sachnr = model.GetParam("SACHNUMMER");

sachnr_value_asm = sachnr.GetValue();

sachnr_asm = sachnr_value_asm.GetStringValue();



...to set an Parameter:

Code:
Parameter sachnr = model.GetParam("SACHNUMMER");

ParamValue sachnr_value = pfcModelItem.CreateStringParamValue(sachnr_neu);

sachnr.SetValue(sachnr_value);



...to regenerate a model:

Code:
RegenInstructions inst = pfcSolid.RegenInstructions_Create(new Boolean(true), new Boolean(true), null);

Solid solid = (Solid) model;

solid.Regenerate(inst);



I hope this would help you...



Bye.
 

Sponsor

Back
Top