cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

We are happy to announce the new Windchill Customization board! Learn more.

Retrieve attributes in Workflow?

RavinKayasth
1-Newbie

Retrieve attributes in Workflow?

Gurus',

Can I retrieve part soft-type attributes in workflow? Also I need them
to be visible and/or updatable thru the task form (Complete Task page).
Is this posible?

E.g. I have a Mpart, which is a soft-type of WTPart, and has 3
attributes; color,location and status, which I want to retrieve in an
activity of a workflow, and allow the user to update them.

Thanx,
Ravin

Please do not print this email unless it is absolutely necessary.

The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments.

WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.

www.wipro.com
9 REPLIES 9

I have been using a combination of Webjects and customized code to do this.

I created some classes to update and query windchill attributes and then call these classes from within workflow expression robots.



In Reply to Ravin Kayasth:

Ravin,

Have you managed to do this ?

I have a similar problem - attempting to update soft attributes through workflow tasks. I can get variables set by the user but how do you retrieve the values from object attributes and update them ?

Thanks

Ian

In my presentation on Change Management from the PTC/USER 2009 conference I gave examples on how to get/set IBA's from workflows. There is example code in the appendix of the presentation - can be found here -

http://portal.ptcuser.org/p/do/sd/sid=704&type=0

Jeff Zemsky
-

Thanks Jeff, but that link is broken !

Regards

Ian

Sorry for any confusion - the PTC/USER 2009 Conference files are still access protected. I put a copy where everyone can get it - here is the link

http://portal.ptcuser.org/p/do/sd/sid=1103&type=0

Jeff Zemsky
-

Thanks,

I changed the first line to reference my own soft type (child of wt.change2.WTChangeIssue):-

com.lmco.Problem_Report pr= (com.lmco.Problem_Report) primaryBusinessObject;

However this throws a Syntax error:-

"D:\PTC\Windchill_9.0\Windchill\temp\WfExpression14342620.java:28: package com.lmco does not exist
com.lmco.Problem_Report pr= (com.lmco.Problem_Report) primaryBusinessObject; "

Looks like a problem with the way I am referencing my soft type "com.lmco.Problem_Report" - any ideas?

Many thanks

IAn

BTW,

Where does the System.out.println output go ?

Thanks

Ian

On 12/16/09 04:06, Ian Webb wrote:
> BTW,
>
> Where does the System.out.println output go ?

It will go to the log files under <windchill>/logs. Look in the method server,
background method server (if you have one running), and the server manager logs.

>
> Thanks
>
> Ian
>
>


--
------------------------------------------------------------------------
Randy Jones
Systems Administrator
Great Plains Mfg., Inc.
1525 E North St
PO Box 5060
Salina, KS USA 67401
email: -
Phone: 785-823-3276
Fax: 785-667-2695
------------------------------------------------------------------------

Thanks,

I now need to reference other attributes,

I can get Name, Number, Descriptionetc for example onChange Request:-

wt.change2.WTChangeRequest2 cp = (wt.change2.WTChangeRequest2)primaryBusinessObject;
String name = cp.getName();

But what about:-

Lifecycle State

Last Modified

Modified by

Created On

Created by

etc ???

Top Tags