Try setting it through a function.
That is how I do onload events.
script language=Javascript
function focusme()
{
document.PracticeDetail.PName.focus();
}
/script
BODY onload='focusme()' bgcolor=white
-Original Message-
From: Larry Juncker [mailto:[EMAIL PROTECTED]]
Sent:
Larry,
Try this syntax:
document.FORMNAME.elements['FIELD_NAME'].focus();
Ryan Pieszak
-Original Message-
From: Larry Juncker [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 18, 2002 9:52 AM
To: CF-Talk
Subject: Set focus on a CFINPUT field
Can someone point me to how to properly
focus on a CFINPUT field
Try setting it through a function.
That is how I do onload events.
script language=Javascript
function focusme()
{
document.PracticeDetail.PName.focus();
}
/script
BODY onload='focusme()' bgcolor=white
-Original Message-
From: Larry Juncker [mailto
Still to no avail
-Original Message-
From: Ryan Pieszak [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 18, 2002 10:06 AM
To: CF-Talk
Subject: RE: Set focus on a CFINPUT field
Larry,
Try this syntax:
document.FORMNAME.elements['FIELD_NAME'].focus();
Ryan Pieszak
-Original
Right, you need to do it as a function in an onLoad event because
if you don't it will immediately look for that formfield before
it exists. Onload waits until the page is fully loaded before
executing the function.
BJ
= = = Original message = = =
Try setting it through a function.
That is
]]
Sent: Thursday, April 18, 2002 10:11 AM
To: CF-Talk
Subject: RE: Set focus on a CFINPUT field
I have tried that also. Exact code as you have written below.
It appears that the ColdFusion javascript doesn't allow the hardwritten code
to
populate.
-Original Message-
From: David DiPietro
that the ColdFusion javascript doesn't allow the hardwritten
code to
populate.
-Original Message-
From: David DiPietro [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 18, 2002 10:00 AM
To: CF-Talk
Subject: RE: Set focus on a CFINPUT field
Try setting it through a function.
That is how I do onload events
for the generated page?
- Matt Small
-Original Message-
From: Larry Juncker [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 18, 2002 11:11 AM
To: CF-Talk
Subject: RE: Set focus on a CFINPUT field
I have tried that also. Exact code as you have written below.
It appears that the ColdFusion
-Talk
Subject: RE: Set focus on a CFINPUT field
Right, you need to do it as a function in an onLoad event because
if you don't it will immediately look for that formfield before
it exists. Onload waits until the page is fully loaded before
executing the function.
BJ
= = = Original message
Thank You Ryan
This code worked absolutely perfectly on all three browsers.
-Original Message-
From: Ryan Pieszak [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 18, 2002 10:15 AM
To: CF-Talk
Subject: RE: Set focus on a CFINPUT field
Larry,
This is the exact code we use for out logon
10 matches
Mail list logo