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

how to show custom error message to the user on exception while saving work item for operation participant

 Hi,

I Developed an operation participant for setting the Iteration planned attribute to current iteration and when there is no current iteration for the timeline it should give a proper error message to the user.
 I handled this using the following code snippet

 collector.addInfo(collector.createInfo(
                                   DefectIterationConstantsEnum.OPERATION_FAILED.getValue(),
                                   DefectIterationConstantsEnum.NO_ITERATION.getValue()));
                           throw new TeamRepositoryException(
DefectIterationConstantsEnum.NO_ITERATION.getValue());

it is working fine but my concern is 

The custom message is shown in the Team Advisor view but not beside the workitem name.

beside the work item name Im getting the following message

'Exception Running followup Action'

can this be done ?

Thanks
Surender


0 votes

Comments

I do not think you can provide a better message.

Thanks sam for

but my concern is that i n the Team Advisor view it is showing as

Problem:

UnHandled exception

then my custom message

Reason :

here comes the description of my plugin.

I dont want the Unhandled exception message under the problem and under reason I want my custom message to be displayed but not the description.

My second concern is that cant we show the custom message just beside the workitem name instead of showing that in Team advisor view.

we can do the following instead of throwing the TeamRepositoryException. 


IReportInfo info = collector.createInfo("message to be displayed beside the work item name", "problem information");
info.setSeverity(IProcessReport.ERROR);
collector.addInfo(info);

setting the severity to error will not save the workitem
if we dont set the severity it will save the work item.



One answer

Permanent link
As far as I know there is no way to provide the error message somewhere else.

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
× 10,937

Question asked: Apr 19 '14, 3:18 p.m.

Question was seen: 4,117 times

Last updated: May 05 '14, 4:54 a.m.

Confirmation Cancel Confirm