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

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

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

vuchekar
10-Marble

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

3 REPLIES 3
RandyJones
19-Tanzanite
(To:vuchekar)

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.

ddemay
7-Bedrock
(To:vuchekar)

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.

ddemay
7-Bedrock
(To:ddemay)

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.

Announcements

Top Tags