Expand my Community achievements bar.

Radically easy to access on brand approved content for distribution and omnichannel performant delivery. AEM Assets Content Hub and Dynamic Media with OpenAPI capabilities is now GA.

Accessing Form Variables

Avatar

Former Community Member
I need to change some of the form variables via form1.DEF-0121.sec1.detail.info.docTitle::click



DEF-0121 is the page name

sec1 is a table

detail is a row group that includes 'info' and 'infoMore'

docTitle is a text field



I tried to change the form variable under the click event in docTitle with the following code:



docFocus.value=this.parent.index;



where as docFocus is a form variable I set up with an initial value of 0.

console.println(this.parent.index) tells me that its returning the desired value, however, when I tried console.println(docFocus.value), it still prints the initial value of docFocus, which is 0.



It probably sounds simple but any help to the right direction would be appreciated, thanks



Dan
5 Replies

Avatar

Former Community Member
The property you want is rawValue not value.

Avatar

Former Community Member
Can you add an app.alert(docFocus.rawValue) before the var nIndexTo statement and see what it returns?

Avatar

Former Community Member
Hello, i have one var array in js and i put on it data from database. The first time it run ok but when an avent fire, my var lose values. It can be? variables lose values?

I only need two combos whit relation. For example country and states but i can't get to work.

Avatar

Former Community Member
Can you post a sample of your issue to livecycle8@gmail.com and I will have a look at your form.