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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Where's the list of button.Attributes as used in this previous thread? 1

Status
Not open for further replies.

christheprogrammer

Programmer
Jul 10, 2000
258
CA
See this thread below:

thread855-296976

It was the one about turning the mouse pointer into an hourglass. The solution was to access the Attributes of the button, so that when it was clicked ("onclick"), an hourglass would appear. Like this:

myButton.Attributes("onclick") = "javascript: hourglass();"

My question is, where is the list of Attributes for any given control? I cannot find it anywhere, and since they are referenced as strings, I am dubious as to whether they are supported properly given that VB is now object oriented...
I am just really curious as to what magic can be done by referencing attributes for controls :)
Cheers

Life is like a box of chocolates, sweet
 
That is simply adding a client side attribute to the button. Therefore, any valid client side attribute:

onClick - onFocus - onKeyUp - onKeyDown - etc...

would be valid for putting in there. Actually, you could probably add things like "onChris" if you wanted to, w/o any error message... just that it wouldn't do anything, since the resulting button would look like this:

<input type=submit onChris=&quot;chris();&quot; ... >

And since there's no chris event for buttons, it just wouldn't do anything. You can check out for a full listing of valid events for the various client side html objects.

:)
paul
penny1.gif
penny1.gif
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top