Click to See Complete Forum and Search --> : Javascript Equivalent of Set??


jcrash
04-11-2003, 04:23 PM
I need to find the javascript equivalent of this vbscript statement:

Set objChild = Document.All("C" & Mid(strParentId, 3))

It is for a menu where I dont know how many elements there will be with that ID. I then set the visibility with

objChild.Style.Display = ""
or
objChild.Style.Display = "none"


I need to convert this menu from IE only to being cross browser compliant.

thanks for any and all help!

AdamGundry
04-11-2003, 04:29 PM
I think you need the following:

var objChild = document.getElementById("C" + strParentId.charAt(3));

Adam