Solved

Javascript 'getElementById' not working with dynamic html

Posted on 2011-02-17
6
261 Views
Last Modified: 2012-05-11
Hello Experts -

I'm creating some dynamic HTML with .NET code, and when I try to reference a hidden input element with Javascript, it's giving me an 'Object Required' error. I'm using this code with Ajax, so I figured it's safe.

Any thoughts?

Thanks
0
Comment
Question by:tablaFreak
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
ID: 34921615
>I'm creating some dynamic HTML with .NET code

View source of the page to see/check it
0
 
LVL 82

Assisted Solution

by:leakim971
leakim971 earned 500 total points
ID: 34921622
check the id attribute, it's case sensitive
0
 

Author Closing Comment

by:tablaFreak
ID: 34921729
Thanks for your help - duh, when I checked, I discovered I was naming the elements with 'name=""' as opposed to 'id=""'. So
0
Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

 

Author Comment

by:tablaFreak
ID: 34921732
that was a humbler.
0
 
LVL 82

Expert Comment

by:leakim971
ID: 34921785
thanks for the points! have a nice end of week and lot of fun!
0
 

Author Comment

by:tablaFreak
ID: 34921877
sure thing - you, too!
0

Featured Post

Salesforce Made Easy to Use

On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses

624 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question