Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: (Still Newbie) WO Programmatic equivalent to JS select focus



Hi there,

Try something like this:

<html>
<head>
<meta name="generator" content="HTML Tidy for Mac OS X (vers 1st May 2003), see www.w3.org">
<title>Test page</title>
</head>
<body>
Test Page
<table border="1" cellpadding="1" cellspacing="1" summary="Login Panel Table">
<tr>
<td align="center">
<webobject name="loginPanelForm">
<table>
<tr valign="middle">
<td align="right">
Login&nbsp;ID:
</td>
<td align="left">
<webobject name="loginField"></webobject>
</td>
</tr>
<tr valign="middle">
<td align="right">
User&nbsp;ID:
</td>
<td align="left">
<webobject name="userField"></webobject>
</td>
</tr>
<tr valign="middle">
<td align="right">
Password:
</td>
<td align="left">
<webobject name="passwordField"></webobject>
</td>
</tr>
</table><br>
<webobject name="loginButton"></webobject>
</td>
</tr>
</table><br>
<webobject name="focusScript"></webobject>
</body>
</html>



focusScript: WOJavaScript { hideInComment = true; scriptString = "document.LoginPanel.LoginId.focus();"; type = "text/javascript"; }

loginButton: WOSubmitButton {
	action = submit;
	value = "Login";
	name = "Login";
    class = "button";
}

loginField: WOTextField {
	value = loginLoginId;
	name = "LoginId";
}

loginPanelForm: WOForm {
	multipleSubmit = true;
	name = "LoginPanel";
	action = buttonSubmit;
}

passwordField: WOPasswordField {
	value = loginPassword;
	name = "PasswordField";
	onChange = "handleLogin();";
}

userField: WOTextField {
	value = loginUser;
	name = "LoginUser";
}


On Sep 14, 2004, at 6:04 AM, Erwin wrote:

Even searching archives or reading the 4 books I bought on WO
I could not find how to focus to a specific WOTextField in a WOForm and select the data in this WOTextField....
I don't want to use JS but I would like to do it from my validationFailedWithException method....
is it possible ?


thanks for your help

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/ email@hidden


This email sent to email@hidden

Jerry E. Porter
Software Engineer
Wireless Matrix Corporation
102, 1530 - 27th Ave. NE
Calgary, Alberta, Canada
T2E 7S6
Main: 1-403-250-3949
Fax: 1-403-250-8163
email@hidden
http://www.wirelessmatrixcorp.com


_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/email@hidden

This email sent to email@hidden
References: 
 >(Still Newbie) WO Programmatic equivalent to JS select focus (From: Erwin <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.