Skip to Content
0
Former Member
Jan 17, 2006 at 07:05 AM

Using values passed from 2nd JSPDynPage

13 Views

Hi,

I tried successfully to pass value (text of a chosen listbox item) from first jspdynpage to other.

Now, i want this value to be shown in TextView or InputField.

How do i go about doing that?

I tried using:

 	 <SCRIPT language="JavaScript">
 	 		EPCM.subscribeEvent("urn:com.sapportals.*", "testEvent", onWake);
 	 		function onWake(eventObj){
 	 			var tempStore = EPCM.loadClientData("urn:com.sapportals.portal.*", "tempStore");
 	 			if (tempStore!=null){
	 	 			var success_message = eventObj.dataObject;
	 	 			var funcName = htmlb_formid+ "_getHtmlbElementId";
					func = window[funcName];
					var selected = eval(func("success_message"));
					selected.setValue(tempStore);
	 	 			}
	 	 		else
	 	 			alert('hello2');
 	 		}
	 </SCRIPT>

but it gives me error saying "Object not found"..

it is basically erroring out at

var selected = eval(func("success_message"));

I can understand that it does not recognize this success_message inputfield so far...

Any workarounds or suggestions?

Second problem is dataObject shows null values... i have tried all combinations by making onWake in EPCM.subscribe as "onWake" etc etc but it works only if i use onWake...

Please get back to me asap....

Regards,

Dev.

PS: Points will be awarded!