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

Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X

Translate the entire conversation x

I can't add a listener of WorkItem objects

è吕
3-Newcomer

I can't add a listener of WorkItem objects

截图02.png

this's my codes, and i can't catch the event target of workitem.

can you help me ,thank you!

ACCEPTED SOLUTION

Accepted Solutions
BineshKumar1
13-Aquamarine
(To:è吕)

Try this

if((event.getEventType( ).equals( PersistenceManagerEvent.INSERT )) && ( target instanceof WorkItemLink))

Thanks

Binesh Kumar

View solution in original post

4 REPLIES 4
BineshKumar1
13-Aquamarine
(To:è吕)

Try this

if((event.getEventType( ).equals( PersistenceManagerEvent.INSERT )) && ( target instanceof WorkItemLink))

Thanks

Binesh Kumar

thanks for your answer,and how can i get WorkItem with WorkItemLink ?

BineshKumar1
13-Aquamarine
(To:è吕)

WorkItemLink workitemlink = (WorkItemLink) target;

WorkItem workitem = workitemlink.getWorkItem();

it works ,

thanks a lot ~~

Announcements
Top Tags