Javascript locks all drop downs from working

I have a web page with code behind. The page contains several combo boxes, and goes through some validation rules after user clicks the 'submit' button. If a validation error is found, a hidden <div> is displayed on the web page with the errors. The page scrolls up to the validation <div> using some javascript; see below which is executed from the code behind. For some reason, the javascript is causing the combo boxes and text input fields to be frozen. If the page is refreshed, the user can then modify or update the input controls. Anyone have an idea what is going on?


        Dim script As String = "document.getElementById('ValidationResults').scrollIntoView(true);"
        ScriptManager.RegisterStartupScript(Page, Page.GetType(), "key", script, True)
Stacey FontenotAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

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.

Julian HansenCommented:
Dim script As String = "document.getElementById('ValidationResults').scrollIntoView(true);"
        ScriptManager.RegisterStartupScript(Page, Page.GetType(), "key", script, True) 

Open in new window

This is not JavaScript.

This is but is meaningless without a context - can you give us the client side code (a link or view source and then cut and paste html here)

Open in new window


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
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
Visual Basic.NET

From novice to tech pro — start learning today.