on 12-11-2007 9:54 AM
hi everyone,
Can any body send tutorials on how to use scriptng in interactive form.
Actually i have a requirement ,to make a text field visible based on the value that i
enter in other text field
I am beginner and cannot able to achieve it,
Please send any examples or how to approach it
Thanks in advance
Hi Madhavi,
There are few good scripting tutorials located at the following location:
http://www.adobe.com/devnet/livecycle/designer_scripting_samples.html
Simply put, this is how you would place scripting for your purpose:
1) Open your form in Adobe LiveCycle Designer.
2) Select the "text field" that should trigger the event.
3) Then Select "change" event from the "Show" dropdown box (located on top, just below the file menu)
4) Write your JavaScript here.
Hope this helps.
Regards,
Harman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi check the follwoing link to get more info about script
<a href="/people/juergen.hauser2/blog/2007/05/30/useful-documentation-for-developing-interactive-forms:///people/juergen.hauser2/blog/2007/05/30/useful-documentation-for-developing-interactive-forms
sample code as follows
second text2 field on load event ,write the following code
if(data.text1.rawValue=="CAR")
then
this.access = "readonly"
this.presence = "visible"
else
this.presence = "invisible"
this.access = " "
endif
hi,
When i have written xfa.host.messageBox("Textfield is changed ", "Warning", 3); in the change event of the text field and trying to enter data into it i am getting displayed with a warning message(a alert message box).
But i could not understand why the other text field is not getting invisible.
I am sending the code which i have written in the chage event of text field2.
in form ready event of textfield2 i have initialized the raw valu as hai
if(subform3.TextField2.rawValue == "hai")
{
subform3.TextField4.presence = "visible";
}
else
{
subform3.TextField4.presence = "hidden";
}
xfa.host.messageBox("TextField is changed","warning",3);
Please tell where i am doing mistake
Thanks in advance
Hi madhavi kotra ,
Scripting
Adobe LiveCycle Designer uses the script languages JavaScript and FormCalc. FormCalc is a simple Adobe script language for typical form calculations, including mathematical and logical functions, and date and character string functions. For more information about FormCalc, and a FormCalc language reference, see the online help of Adobe LiveCycle Designer.
To achieve the best possible performance when processing forms, use as little scripting as possible in the form itself. If possible, perform all calculations and data analysis in the application program, before the form is called
The following websites provide details on scripting:
Improving the Performance of Adobe® LiveCycle Designer Forms(scripting)
http://www.adobe.com/devnet/livecycle/articles/lc_designer_perf_guidelines.pdf
SAP® Interactive Forms by Adobe® Development Introduction
http://www.nl4b.com/Adobe/Invitation_SAPBrussels_Q407.pdf
cheers!
gyanaraj
****Pls reward points if u find this helpful
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi madhavi,
Please click on the other fiedl and go to FORm calc and write the below code in change event
if $.rawvalue <> " " then
textfield.presence = "VISIBLE"
endif
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
76 | |
9 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.