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

Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X

How to display the all users of the Windchill (Means All user names)

saitha
1-Newbie

How to display the all users of the Windchill (Means All user names)

Hi Freinds,

How to display the all users of the Windchill (Means All user names).Can you suggest any api ?

Regards,

Sandeep

1 ACCEPTED SOLUTION

Accepted Solutions

List<WTUser> resultList = new java.util.LinkedList();

QuerySpec querySpec = new QuerySpec(WTUser.class);

QueryResult queryResult = PersistenceHelper.manager.find(querySpec);

while (queryResult.hasMoreElements())

{

resultList.add((WTUser) queryResult.nextElement());

}

View solution in original post

5 REPLIES 5

List<WTUser> resultList = new java.util.LinkedList();

QuerySpec querySpec = new QuerySpec(WTUser.class);

QueryResult queryResult = PersistenceHelper.manager.find(querySpec);

while (queryResult.hasMoreElements())

{

resultList.add((WTUser) queryResult.nextElement());

}

Hi,

Yes i done same thing,Will it dispaly all usernames ?i was login windchill by using wcadmin username ,but it is not dispalying the wcadmin

QuerySpec qSpec =

new QuerySpec(WTUser.class);

QueryResult qrMasters = PersistenceHelper.

manager.find(qSpec);

while(qrMasters.hasMoreElements()){

WTUser userName=(WTUser)qrMasters.nextElement();

System.

out.println(userName.getName());

}

for the above code the out put is

demo

adminstartor

getuser

My doubt is why wcadmin is not displayed but i was connect to the windchill by using wcadmin username can u explain ?

Regards

Sandeep

adminstartor is wcadmin

Hi

Ok tahnk you

Regards,

Sandeep

saitha
1-Newbie
(To:saitha)

Hi,

How to get the owner user of the exsiting part ?

Regards,

Sandeep

Top Tags