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

Object Required 'this'

Status
Not open for further replies.

ralphtrent

Programmer
Jun 2, 2003
958
US
Hello
I have the following code in an ASP file:
<tr onMouseover=&quot;this.bgColor='<%=bgRollColor%>'&quot;>
bgRollColor is different based on what record is being displayed. when I put my mouse over the row I get and error Object Required 'this'.

Any Idea's?
 
ralph,

What browser are you seeing the error in? It works fine for me in IE6...

That aside, if you change your code to read:

Code:
<tr onmouseover=&quot;this.style.backgroundColor='<%=bgRollColor%>'&quot;>

Where 'bgRollColor' equates to something like '#FF0000', 'red', etc, then that should work in most browsers.

Hope this helps,

Dan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top