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

How to get Object details from selected row via custom action on separate jsp page

Granite

How to get Object details from selected row via custom action on separate jsp page

Hi All,

I have created a Custom Action link, which triggered an jsp page.

This custom Action is made available on Right Click actions and Details page action of an object.

now i want to get the selected object details like name, number on .jsp page. how i can achieve this.

i have tried "NmCommandBean".

Please let me know if you have any information on this.

Regards,

Vivek

Tags (1)
3 REPLIES 3

Re: How to get Object details from selected row via custom action on separate jsp page

Vivek Uchekar wrote:

Hi All,

I have created a Custom Action link, which triggered an jsp page.

This custom Action is made available on Right Click actions and Details page action of an object.

now i want to get the selected object details like name, number on .jsp page. how i can achieve this.

i have tried "NmCommandBean".

You can try something like the following:

<%@ include file="/netmarkets/jsp/components/beginWizard.jspf"%>

<%@ include file="/netmarkets/jsp/components/includeWizBean.jspf"%>

<%

Object context = commandBean.getPageOid().getRefObject();//get the right clicked object

WTPart wtp = (WTPart)context;//assume object was a WTPart

%>

<br>Part name = <%=wtp.getName() %> number = <%=wtp.getNumber() %>

You also need to check out Felco Solution's "Windchill Customization" course:

FELCO Solutions

This is an excellent course.

Re: How to get Object details from selected row via custom action on separate jsp page

You should create the Pet example from scratch using the Customizer's guide for this reason.

If you use a debugger, you can actually see multiple NmCommandBeans being exchanged back and forth between client and server.  Sometimes they are arrays or collections of NmCommandBeans.   There is a chance that your code is peering into the wrong NmCommandBean, but without more detail, no further assistance can be provided.

Re: How to get Object details from selected row via custom action on separate jsp page

I should also add that the action you created likely has a problem in its cnfiguration. NmCommandBeans do act wierd when there is a flaw in action configuration.