Welcome to the IBM Collaboration Solutions Community IQJam
UsernamePassword
Reset Password | Register
   
Home | Tags | Help
How to get value from Repeater Control. 

Hi All,

I will be very thankful to you for your kind support and help.

Scenario is:

I have a repeater control on the Xpage and that repeater contorl contains two edit box named EditBox1 and EditBox2. At the bottom of this repeater contorl I have a save button which would create documents by extracting these two pair of edit box field. My data source for repeater control is @DbColumn which repeat these contorl 3times or 4times or based on the number of value returned by @DbColumn. Now my problem is that I am not able to extract these value from multiple edit boxes when it rendred to the browser. What Id should I used to get value of all boxes or how I can acheive these. Please help me.

I will be very thankful to you for your kind response.

With Regards,

Vikas K Sinha

Domino Development / XPages
Vikas Sinha - over 2 years ago |  |  | Viewed 829 times
File Name
test.jpg

There are 3 answers

0votes

Hi Vikas,

  The scope of row variable of a repeat control is within the repeat control only. You will not be able to access from outside it.

Alternatively you can set the variables to scoped variables (requestScope, viewScope or sessionScope) and get it outside your repeat Control.

Hope this helps.

Mervin

Mervin Thomas - about 1 year ago | 
Voting
Vote on the answer to show whether you think the answer is correct or useful to the rest of the community.

Answers with more votes are more visible to the rest of the community
0votes

What you could do is the use the functionality the JSF framework ( on which xpages is build ). The context global can be used to retrieve the request ( getRequest() if im not mistaken ) . In this request exists a method ( getParameterMap()) which contains all the parameters that where send with the request.

Simple iterating over this map will return all the submitted values. This map contains ALL fields that where available at the time of the submit. So the fields generated by the repeater are also available. The only thing you would need to know are:

  1. The ID generated for the repeater by xPages ( something like <viewID>:<repeatID> use firebug to see the generated IDś).
  2. the ID's that where generated from the editboxes inside the repeat. These idś correspond with keys in the parameter map.

Simple reading the values and do a document.replaceItemValue("field",value). Would do the trick here. It is not as easy as you would expect with notes development but it is an option you can consider

jeroen somhorst - about 1 year ago | 
Voting
Vote on the answer to show whether you think the answer is correct or useful to the rest of the community.

Answers with more votes are more visible to the rest of the community
0votes

I simulated something for you, please review solution.jpg, I will reply you accordingly.

File Name
solution.jpg
Atul Saxena - about 1 year ago | 
Voting
Vote on the answer to show whether you think the answer is correct or useful to the rest of the community.

Answers with more votes are more visible to the rest of the community

Latest Answers for Domino Development / XPages 

How to call LS agent in xpage
Vijay Kumar - 6 months ago
Multi-values in an xPage view panel column
Judy Kilpinen - 8 months ago
From CSJS refresh a panel dijit.TooltipDialog
daniele grillo - about 1 year ago
How to get value from Repeater Control.
Atul Saxena - about 1 year ago
doing a partial update "beforepageload"
jeroen somhorst - about 1 year ago
How to get value from Repeater Control.
jeroen somhorst - about 1 year ago
How to get value from Repeater Control.
Mervin Thomas - about 1 year ago
Where Would I Delete My Cookie?
Lenni Sauve - over 2 years ago
Query_String value empty with agent URL from xpage
Andy Cunliffe - over 2 years ago
textfield formatting
Ben Poole - over 2 years ago
File Upload/File Download using Managed Beans
Toby Samples - over 2 years ago
File Upload/File Download using Managed Beans
Andy Cunliffe - over 2 years ago

Experts for Domino Development / XPages

There are no experts to display