Help with Javascript menu in classic asp application

Hi Guys

I have a menu which has worked fine in previous applications. There is a bit of code involved in this so I have put the html, javascript and css in JSBin at

The main problem I am experiencing is that the dropdown menu under "Calendar Views" does not dropdown -

My main problem is an error being returned on the SetBttnStyle function - the error in JSBin seems to be that the object has no method - I am not good with javascript so I have no idea what this means.

I would be grateful if someone can point out what the rror mean and how to fix it, with commenting in the code so I understand.


Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Scott Fell, EE MVEDeveloper & EE ModeratorCommented:
To start, please paste your code into the validator  There are a lot of errors and it is possible something there is preventing it from working. I wouldn't go further until that is cleaned up.

Next, are you sure the drop down is supposed to be table's and rows and not an unordered list?  Where did you get this code from to compare?

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
dwe0608Author Commented:
Hi Padas,

this code was extracted from a script I obtained many years ago, which I still use today - I ported it across from an old app - the original source that I obtained it from is sadly, as almost usual these days - long gone - so I cant go back and compare - I have considered renewing the scripts to something similar to this = which is an unordered list and relatively uncomplicated ... what do you think ?
Scott Fell, EE MVEDeveloper & EE ModeratorCommented:
Yes, I think that is much better in the long run.
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

I have used that EXACT (the one referenced in the link above) same script in some of my projects.
It is okay, but I have evlved to using pure CSS for drop-downs now.  It's much more fluid, and still works if your user does not have JS enabled.
May want to consider moving away from JS for menus.

try Googling "pure css dropdown menu tutorial"
Scott Fell, EE MVEDeveloper & EE ModeratorCommented:
It is a bit older.  I think you can run into some issues with mobile with pure css.  I am to the point where most new sites uses or as a base and I use the core nav function there.

You don't want or need to use the default "look" and you can make your own. But the core of how it works is good.  

Also note that the newest version of bootstrap lost the ability for nested sub menu navigation because mobile would not be able to deal with it easily.    Even if you use something else, think about that.  Easily 40% to 50% of your users now are mobile or touch screen.
dwe0608Author Commented:
Thanks for the input guys
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.