cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Data Selection

Former Member
0 Kudos

Hi Experts,

In my application when i am selecting the multiple rows which i entered earlier in the popup window, it's getting populated into main window.

But in main window only one input field is there,so only the fiest record is getting displyed after selection.

Rest of the records i am not able to display in the main window.And the problem is i can't add more than one input field in main window. Rest of the values will be passed into R3 through coding but it can't be displayed on screen.

So please advice me on these two scenarios.

1 . How to populate multiple row values(input fields in popup window with value enterd by user) into

main view. In main view only one input field is there.

2 . How to pass all the selected values from main window to R3 by webdynpro coding.

All the values coming from popup need to be passed even though only one value is displayed.

Here the input field in main window is mapped to one model attrribute.

Thanks a lot.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Write following code on action of button.

Here Ctx_vn_outmeasdoc() is value node which is bound to the table.and it is structure binding node with model node.Zrent_Measdoc_Save_Input is rfc.



// rfc intialization

 Zrent_Measdoc_Save_Input inp1=new Zrent_Measdoc_Save_Input();
		wdContext.nodeZrent_Measdoc_Save_Input().bind(inp1);
// 

int size=wdContext.wdContext.nodeCtx_vn_outmeasdoc().size();
int leadSelected=wdContext.nodeCtx_vn_outmeasdoc().getLeadSelection();

for(int i=0;i<size;i++)
{

IPublicZRENT_MEASDOC_SAVEModelCust.ICtx_vn_outmeasdocElement src =wdContext.nodeCtx_vn_outmeasdoc().getCtx_vn_outmeasdocElementAt(i);

IPublicZRENT_MEASDOC_SAVEModelCust.I<your model node)>modelnode=wdContext.node<your model node>.create<your model node>();

if (wdContext.nodeCtx_vn_outmeasdoc().isMultiSelected(i) || leadSelected == i)
	{
		WDCopyService.copyCorresponding(src,modelnode);
		wdconext.node<modelnode>.addelement(modelnode);
	}
		
}
         

Edited by: Abhilasha Dahare on Mar 31, 2009 10:26 AM

Answers (1)

Answers (1)

Former Member
0 Kudos

hi

Can you be more clear with your question please ?

with respect to your second scenario of how to set the data to the RFC

first thing fetch the data from the Input fields .

Suppose consider the ex,

String name = wdcontext.currentcontextElement.getname();

ZRFC rfc = new ZRFC() ; // Rfc in to which you have to pass the data .

the above line you can even change w.r.t the Model Class you are storing in .

rfc.setName(name);

wdcontext.node<NodeName>.bind(rfc);

or if you are setting in directly to the RFC

wdcontext.current<RFCName> . modelobject.set(rfc);

then execute the RFC .