cancel
Showing results for 
Search instead for 
Did you mean: 

How to read Action Information from a WebDynpro Callable Object?

Former Member
0 Kudos
61

Hello Experts,

I am using a Web Dynpro Callable Object in my guided procedure application. Definitly I will be using this Web Dynpro under an Action, say Action123. How can I get the name of this action or any other details of the action from this web Dynpro callable object using an API? I mean is there any Guided Procedure API which would help me to read the information of the action which holds the web dynpro callable object? I want to use this information in the execute method of the web Dynpro callable object.

Thank You,

mansooralip1

View Entire Topic
Former Member
0 Kudos

Hi,

I can´t completely understand what you need.

When you are executing a process , and you are executing a callable object you want to get the name of the action that is holding that CO ? or you want to get info about the active version of the Callable Object?

If you need info about the current action, take a look at this excerpt (extracted from sap help --> Completing Actions Using the GP API ) :

*//Retrieving Information about Actionu2019s Parameters, Result States, or Process Exceptions*

IGPActionInstance instance =  rtManager.getActionInstance(processID, actionID, userContext);

if (instance.getTemplate().isAction()){

//the action template

IGPAction action = (IGPAction) instance.getTemplate();

//a collection of IGPAttributeInfo objects

Collection output = action.getOutputParameters().getAttributes();

Iterator itr = output.iterator();

while(itr.hasNext()){

      IGPAttributeInfo attr = (IGPAttributeInfo)itr.next();

      String name = attr.getTechName();

      int type = attr.getType();
}
.....
//an array of IGPResultStateInfo objects    

IGPResultStateInfo[] states = action.getResultStates();

for (int i=0; i<states.length; i++){

   String resultState = states<i>.getName();
.....
}

BUT, if what you need is to get information independent from the executing process (las active version of CO for example) then you are talking about the GP Development Objects, and you should use that libraries to get for example Retrieving Actions with Status ACTIVE ,Retrieving Objects Information and so on, please if this is the case refer to this link ,(it contains code examples and some explanation):

HELP SAP then click on Modeling and Configuring Workflows Using the GP API --> Editing GP Development Objects

Hope been helpful,

Best regards,

Marco.

Edited by: Marco Ustarroz on Jun 5, 2009 3:40 PM