Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ReportNet, use Javascript to Validat the user's input

Status
Not open for further replies.

willfast

Programmer
Jan 18, 2007
2
CA
Hi everyone, I want to use Javascript to validate the user's input in the text impropt, change it to upper_case.

I am using the following script:

<script>
// This script will upper_case the input value of the TEXT prompt named UID.
function ValidatePage(){
document.formWarpRequest._textEditBoxUID.value=document.formWarpRequest._textEditBoxUID.value.toUpperCase();
promptButtonFinish();
}

for(var i=0; i<pageNavigationObserverArray.length; i++){
cntlName = eval( pageNavigationObserverArray );
if(cntlName.m_oParent.onclick.toString().indexOf('promptButtonFinish()')>0){
cntlName.m_oParent.onclick = ValidatePage; }
}
</script>

The issue is when user click the 'submit' button everything is fine, but if user press enter key it does not do the validate function.
Is there anything I can do for that?
Thanks a lot.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top