Novice here - using notepad only .....
function MenuBarIn(E)
{
var i;
with (document.getEl ementById(E.id) )
{
style.backgroun dColor = "steelblue" ;
style.top = "90%";
style.height = "10%";
style.borderTop Style = "solid";
style.borderRig htStyle = "solid";
style.borderBot tomStyle = "solid";
style.borderLef tStyle = "solid";
style.borderTop Width = "2px";
style.borderRig htWidth = "1px";
style.borderBot tomWidth = "1px";
style.borderLef tWidth = "1px";
style.borderTop Color = "rgb(102,204,25 5)";
style.borderRig htColor ="rgb(102,204,2 55)";
style.borderBot tomColor ="rgb(36,161,23 2)";
style.borderLef tColor = "rgb(36,161,232 )";
}
// global var
if (giSpanCnt < 14 )
{
// attempt to add 14 span id's each with an Event
for ( i = 0; i < 14 ; i++ )
{
var eleSpan = document.create Element( "SPAN" ) ;
giSpanCnt = giSpanCnt + 1 ;
eleSpan.innerHT ML = goMenuArray[giSpanCnt] ;
eleSpan.id = eleSpan.uniqueI D ;
eleSpan.classNa me = gClassNameMenuO bjects ;
//alert(eleSpan.i d) ;
//eleSpan.id = "IdSpan" + giSpanCnt ;
//var curID = document.getEle mentById(E.id). lastChild ;
document.getEle mentById(E.id). appendChild(ele Span) ;
// ERROR HERE - seems to attach for the First eleSpan but not the rest
// IOW - if the mouse enters the first Span I get back INCREASE - but then
I get back TypeMisMatch error
//eleSpan.attachE vent( "onMouseOve r" , IncText() ) ;
}
}
}
function IncText()
{
alert("Increase ");
}
All help appreciated ......
John McCarthy
function MenuBarIn(E)
{
var i;
with (document.getEl ementById(E.id) )
{
style.backgroun dColor = "steelblue" ;
style.top = "90%";
style.height = "10%";
style.borderTop Style = "solid";
style.borderRig htStyle = "solid";
style.borderBot tomStyle = "solid";
style.borderLef tStyle = "solid";
style.borderTop Width = "2px";
style.borderRig htWidth = "1px";
style.borderBot tomWidth = "1px";
style.borderLef tWidth = "1px";
style.borderTop Color = "rgb(102,204,25 5)";
style.borderRig htColor ="rgb(102,204,2 55)";
style.borderBot tomColor ="rgb(36,161,23 2)";
style.borderLef tColor = "rgb(36,161,232 )";
}
// global var
if (giSpanCnt < 14 )
{
// attempt to add 14 span id's each with an Event
for ( i = 0; i < 14 ; i++ )
{
var eleSpan = document.create Element( "SPAN" ) ;
giSpanCnt = giSpanCnt + 1 ;
eleSpan.innerHT ML = goMenuArray[giSpanCnt] ;
eleSpan.id = eleSpan.uniqueI D ;
eleSpan.classNa me = gClassNameMenuO bjects ;
//alert(eleSpan.i d) ;
//eleSpan.id = "IdSpan" + giSpanCnt ;
//var curID = document.getEle mentById(E.id). lastChild ;
document.getEle mentById(E.id). appendChild(ele Span) ;
// ERROR HERE - seems to attach for the First eleSpan but not the rest
// IOW - if the mouse enters the first Span I get back INCREASE - but then
I get back TypeMisMatch error
//eleSpan.attachE vent( "onMouseOve r" , IncText() ) ;
}
}
}
function IncText()
{
alert("Increase ");
}
All help appreciated ......
John McCarthy
Comment