These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

setFocus

NancyM
Registered: Sep 25 2006
Posts: 40

I am using LiveCycle 7.0 with WindowsXP. I have a multi page form that has hidden pages, but when a radioButton is clicked, the page does become visible but the setFocus is not working. Below is the script on this field.

----- TaxSetupForm.ServiceAuthPage1.CorrespondenceAddress.AddressQuestion.Yes::enter - (JavaScript, client)

if (Fax3.rawValue == null && this.rawValue == null)
{
app.alert("Please enter the fax number.")
xfa.host.setFocus("Fax3");
}
----- TaxSetupForm.ServiceAuthPage1.CorrespondenceAddress.AddressQuestion.Yes::click - (JavaScript, client)

if (this.rawValue != null)
{
AddressChange.presence = "visible";
AddressChange.Corr_Address.rawValue = 1;
xfa.host.setFocus("AddressChange.Corr_DBA_No");
}

Thanks in advance for any help.

My Product Information:
LiveCycle Designer, Windows
MrFlow
Registered: Sep 7 2006
Posts: 13
Try it with Fax3.somExpression instead of "Fax3", also use AddressChange.Corr_DBA_No.somExpression instead of "AddressChange.Corr_DBA_No".

Ciao
Jens
NancyM
Registered: Sep 25 2006
Posts: 40
I have done what you suggested, but it still is not working. Below is what I changed the script to. If I did not understand what you said, please let me know.

----- TaxSetupForm.TaxFilingServiceAuthPage1.CorrespondenceAddress.AddressQuestion.Yes::enter - (JavaScript, client)

if (Fax3.rawValue == null && this.rawValue == null)
{
app.alert("Please enter the fax number.")
xfa.host.setFocus("Fax3.somExpression");
}----- TaxSetupForm.TaxFilingServiceAuthPage1.CorrespondenceAddress.AddressQuestion.Yes::click - (JavaScript, client)

if (this.rawValue != null)
{
AddressChange.presence = "visible";
AddressChange.Corr_Address.rawValue = 1;
xfa.host.setFocus("AddressChange.Corr_DBA_No.somExpression ");
}
MrFlow
Registered: Sep 7 2006
Posts: 13
Try it with

TaxSetupForm.TaxFilingServiceAuthPage1.CorrespondenceAddress.AddressQuestion.Yes::enter - (JavaScript, client)

if (Fax3.rawValue == null && this.rawValue == null)
{
app.alert("Please enter the fax number.")
xfa.host.setFocus(Fax3.somExpression);
}

----- TaxSetupForm.TaxFilingServiceAuthPage1.CorrespondenceAddress.AddressQuestion.Yes::click - (JavaScript, client)

if (this.rawValue != null)
{
AddressChange.presence = "visible";
AddressChange.Corr_Address.rawValue = 1;
xfa.host.setFocus(AddressChange.Corr_DBA_No.somExpression);
}

Ciao
Jens