Hi, I have been looking for an answer to this all morning. I need to use the value from a radio list to populate a text field. I can get the selected numeric value OK using
$.rawValue = form1.#subform[0].Table3.Row1.#subform[0].Location[0].rawValue
but i want to get the text item associated with the value. this could be the caption of the selected radio button, since it is the same thing. I don't want to use an if statement becuase i have have a bunch of forms to create and that would mean changing things in a few times in each form. How can I get the text value from the item column shown below?
Solved! Go to Solution.
Views
Replies
Total Likes
Try the following with two changes to your heirarchy.
1) Currently you do not have a name for Page1. Make sure you assign a name for easy referencing. ("Page1").
2) Set a name for Subform that holds PeriodRadio. ("Subform1").
Thanks
Srini
Views
Replies
Total Likes
Try the following code to get the selected RadioButton's caption.
Thanks
Srini
Views
Replies
Total Likes
this is what i have on the text field but i get a syntax error. i'm afraid i am not great with javascript
form1.#subform[0].TextField4::calculate - (JavaScript, client)
$.rawValue = (form1.#subform[0].Table3.Row1.#subform[0].Location[0].selectedMember().caption.value.text.value);
Views
Replies
Total Likes
Probably the path is not able to resolve to the RadioButton list.
Try
Location.selectedMember().caption.value.text.value..
I see a space after "selectedMember" and the parenthesis after that. Try removing that space as well.
If you still have issues, try posting an image of your Heirarchy highlighting the RadioButton List in it.
Thanks
Srini
Views
Replies
Total Likes
thanks srini, i dont have a space in the actual field, not sure why it showed in my post. it also failed if i changed it to what you suggested. here is my hierarchy, i think the problem must be the path i am putting in the script, can you see where i am going wrong?
Views
Replies
Total Likes
Try the following with two changes to your heirarchy.
1) Currently you do not have a name for Page1. Make sure you assign a name for easy referencing. ("Page1").
2) Set a name for Subform that holds PeriodRadio. ("Subform1").
Thanks
Srini
Views
Replies
Total Likes
great, now its working. Thanks Srini
Views
Replies
Total Likes
Views
Likes
Replies