Getvalue of custom UI attribute
Hi,
i don't know how to get value from custom attributes using the getCustomAttributes() method: i've many custom attribute on my UI and when i'll submit the form ( a typical task item type with other custom fields ) i need to get the value. I tried with
but when i run the code i get a NullPointerException How can i solve ? Thx. |
4 answers
well, getValue() requires a non-null first parameter
Object com.ibm.team.workitem.common.model.IAttribute.getValue(IAuditableCommon auditableCommon, IWorkItem workItem, IProgressMonitor monitor) throws TeamRepositoryException Returns the current -- calculated -- value of this attribute. Parameters: auditableCommon the common auditable library workItem monitor a progress monitor or null ------------------------------------------------------------ The auditable library provides access to IAuditables as an interface available on both the client and the server. On the client it can be obtained as a client library, on the server as a service. ================ Sam |
ok, so if i've to get attributes value ( server-side ) i need another method. There's something that can help me on the wiki ? I tried to find some docs but seems nothing found to solve.
Thanks |
I think you are building an advisor or particpant.
If you are, then the AuditableCommon object is provided as part of the parameters to your advisor code.. (took me a while to find it too)
Sam |
I think you are building an advisor or particpant. Please let me know what should this 'data' to be initialises? thanks Sundar |
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.