By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,714 Members | 1,179 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,714 IT Pros & Developers. It's quick & easy.

can't find error

P: n/a
http://geocities.com/r_bullis/test4.html

Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains.

Otherwise, the page actually validates.

If you can figure out the error, let me know please.

Jul 23 '05 #1
Share this Question
Share on Google+
8 Replies


P: n/a
Richard wrote:
http://geocities.com/r_bullis/test4.html

Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains.

Otherwise, the page actually validates.

If you can figure out the error, let me know please.


Mozilla:

Error: dw_scrollObj is not defined
Source File: http://geocities.com/r_bullis/js/dw_hoverscroll.js
Line: 12

Fix that error first, then follow the errors that Mozilla reports. Then
you can test it in IE. IE is well known to be the worse possible browser
to test pages in.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq
Jul 23 '05 #2

P: n/a

"Richard" <An*******@127.001> wrote in message
news:cq*********@news3.newsguy.com...
http://geocities.com/r_bullis/test4.html

Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains.

Otherwise, the page actually validates.

If you can figure out the error, let me know please.

In IE 6 the page renders nearly correct.
There is a gap between the menu sidebar and the scrolling table.
In Firefox, the page renders as it should.
In Netscape 7.2 the layers don't even show up in the table, but show up
elsewhere as they should.

Jul 23 '05 #3

P: n/a
Hi,

Randy Webb wrote:
Richard wrote:
http://geocities.com/r_bullis/test4.html

Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains.

Otherwise, the page actually validates.

If you can figure out the error, let me know please.

Mozilla:

Error: dw_scrollObj is not defined
Source File: http://geocities.com/r_bullis/js/dw_hoverscroll.js
Line: 12

Fix that error first, then follow the errors that Mozilla reports. Then
you can test it in IE. IE is well known to be the worse possible browser
to test pages in.


Totally true, except if you have Visual Studio .NET installed. Then,
when an error occurs, you have the option to open the page in Studio's
script debugger, which is pretty good. I used to like only Venkman until
now, but after having spent almost one year programming JavaScript for
IE, I got to say that it's handy to have both client-side and
server-side debugged in the same debugger.

Laurent
--
Laurent Bugnion, GalaSoft
Software engineering: http://www.galasoft-LB.ch
Private/Malaysia: http://mypage.bluewin.ch/lbugnion
Support children in Calcutta: http://www.calcutta-espoir.ch
Jul 23 '05 #4

P: n/a

"Randy Webb" <Hi************@aol.com> wrote in message
news:T-********************@comcast.com...
Richard wrote:
http://geocities.com/r_bullis/test4.html

Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains.

Otherwise, the page actually validates.

If you can figure out the error, let me know please.


Mozilla:

Error: dw_scrollObj is not defined
Source File: http://geocities.com/r_bullis/js/dw_hoverscroll.js
Line: 12

Fix that error first, then follow the errors that Mozilla reports. Then
you can test it in IE. IE is well known to be the worse possible browser
to test pages in.


Thanks. I'll look into it. Maybe the file got corrupted or something.
But the source file is online. I double checked to make sure.
Works fine in firefox.
Jul 23 '05 #5

P: n/a
Richard schrieb:
http://geocities.com/r_bullis/test4.html Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains.


OK. I told you bullshit. Remove line 40. The problem is that the original
program shows the content of "lyr1", while you want to hide it. So you have to
hide it again at the end of the initial function "initScrollLayer()". Insert a
new line into this function between "dw_scrollObj..." and "}" (i.e. create a new
line 38):

document.getElementById('lyr1').style.visibility = 'hidden';

viele gre
ralph

Jul 23 '05 #6

P: n/a
Richard wrote:
http://geocities.com/r_bullis/test4.html Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains. Otherwise, the page actually validates. If you can figure out the error, let me know please.

The firefox js console reports:
error: lyr has no properties.

lyr is the variable used to show which "layer" is being applied.

Don't understand this at all.

Jul 23 '05 #7

P: n/a
Ralph 'rkhb' Bauer wrote:
Richard schrieb:
http://geocities.com/r_bullis/test4.html Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains.
OK. I told you bullshit. Remove line 40. The problem is that the original
program shows the content of "lyr1", while you want to hide it. So you
have to hide it again at the end of the initial function
"initScrollLayer()". Insert a new line into this function between
"dw_scrollObj..." and "}" (i.e. create a new line 38): document.getElementById('lyr1').style.visibility = 'hidden'; viele gre
ralph

The only other thing that MIGHT be causing the error is that I have the
layer links outside of a table.
Because when inside of a table, I get no errors.
Don't know why, But if it has to be that way, so be it.


Jul 23 '05 #8

P: n/a
Hi,

Richard wrote:
Richard wrote:

http://geocities.com/r_bullis/test4.html


Was finally able to dress up the coding the way I like it.
But my editor keeps reporting an error on the page.
"line 42....object required".
Regardless of what line 42 contains.


Otherwise, the page actually validates.


If you can figure out the error, let me know please.


The firefox js console reports:
error: lyr has no properties.

lyr is the variable used to show which "layer" is being applied.

Don't understand this at all.


This usually means that the variable lyr was not initialized (that it is
"undefined" or "null". It is empty, has no properties. It's the same
meaning that "object required", only expressed a bit differently.

You should debug your code, observe this lyr variable, and find out why
it's not initialized.

Typically, this could happen if you do something like:

var lyr = document.getElementById( "someId" );

and that no element in the document has this ID. Then the variable would
be null.

Laurent
--
Laurent Bugnion, GalaSoft
Software engineering: http://www.galasoft-LB.ch
Private/Malaysia: http://mypage.bluewin.ch/lbugnion
Support children in Calcutta: http://www.calcutta-espoir.ch
Jul 23 '05 #9

This discussion thread is closed

Replies have been disabled for this discussion.