Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Check category as unassigned(project category) using server API

Hi All,

 I want to check in precondition that work item's category is unassigned (root category) then show error message to select different category.

ICategoryHandle category = workItem.getCategory();

if(category == null ){

 reporterror()

}

As unassigned is root category its not going in side if condition. Is there way to check its unassigned(root category)

 Thanks,

Kavita

0 votes



One answer

Permanent link
print the result of workItem.getCategory() when the category was set to unassigned, this would most likely return the ID associated with the unassigned literal.  use this id/value for comparison in your if statement.. not tested it.. just a quick thought... hope it helps..

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 11,053

Question asked: Apr 08 '13, 9:01 a.m.

Question was seen: 5,939 times

Last updated: Apr 08 '13, 9:12 a.m.

Confirmation Cancel Confirm