Click to return to the DHTML, HTML     
onbeforecut Event     onbeforepaste Event     DHTML Events    
Web Workshop  |  DHTML, HTML & CSS

onbeforeeditfocus Event


Fires before a control enters a UI activated state.

Syntax

Inline HTML <ELEMENT onbeforeeditfocus = "handler" ... > All platforms
Event property object.onbeforeeditfocus = handlerJScript (compatible with ECMA 262 language specification) only
Named script<SCRIPT FOR = object EVENT = onbeforeeditfocus> Internet Explorer only

Remarks

Bubbles Yes
Cancels Yes
To invoke
  • Press the ENTER key or click an object when it has focus.
  • Double-click an object.
Default action Moves the object into a UI activated state.

The designMode property allows Web authors to use the design mode in Microsoft® Internet Explorer, and the property must be set to yes for the onbeforeeditfocus event to fire.

While the browser is in design mode, objects enter a UI activated state when the user presses the ENTER key or clicks an object that has focus, or when the user double-clicks the object. Objects that are UI activated have their own window within the document and allow authors to modify the user interface. To place an object in a UI activated state, the document must be in design mode.

The onbeforeeditfocus event differs from the onfocus event. The onbeforeeditfocus event fires before an object enters a UI activated state, whereas the onfocus event fires when an object has focus.

Event Object Properties

Although event handlers in the DHTML Object Model do not receive parameters directly, the handler can query the event object for data.

Event Object Properties

cancelBubbleSets or retrieves whether the current event should bubble up the hierarchy of event handlers.
clientXRetrieves the x-coordinate of the mouse cursor relative to the client area of the window, excluding window decorations or scroll bars.
clientYRetrieves the y-coordinate of the mouse cursor relative to the client area of the window, excluding window decorations or scroll bars.
returnValueSets or retrieves the return value from the event.
screenXRetrieves the horizontal position of the mouse, in pixels, relative to the user's screen.
screenYRetrieves the vertical position of the mouse, in pixels, relative to the user's screen.
srcElementRetrieves the object that fired the event.
typeRetrieves the event name from the event object.
xRetrieves the x-coordinate of the mouse cursor relative to the parent element.
yRetrieves the y-coordinate of the mouse cursor relative to the parent element.

Applies To

[ Object Name ]
PlatformVersion
Win16:
Win32:
Mac:
Unix:
WinCE:
A, APPLET, AREA, BUTTON, custom, DIV, document, FIELDSET, INPUT type=button, INPUT type=checkbox, INPUT type=file, INPUT type=hidden, INPUT type=image, INPUT type=password, INPUT type=radio, INPUT type=reset, INPUT type=submit, INPUT type=text, MARQUEE, OBJECT, SELECT, SPAN, TABLE, TD, TEXTAREA, TR


Back to topBack to top

Did you find this topic useful? Suggestions for other topics? Write us!

© 1999 Microsoft Corporation. All rights reserved. Terms of use.