Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8142579
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T12:51:40+00:00 2026-06-06T12:51:40+00:00

I have the following: <div id=valueboxes style=overflow-x:hidden;overflow-y:scroll;width:100%;height:200px> However, every time I use the following:

  • 0

I have the following:

<div id="valueboxes" style="overflow-x:hidden;overflow-y:scroll;width:100%;height:200px">

However, every time I use the following:

document.getElementById("valueboxes").innerHTML = html;

I get this error:

'innerHTML': object is null or undefined

Am I doing something wrong?

The html is a table var being appended too by javascript in a for loop using +=.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T12:51:42+00:00Added an answer on June 6, 2026 at 12:51 pm

    That’s because you are executing your code before DOM is fully loaded.

    This should work:

    window.onload = function() {
      document.getElementById('valueboxes').innerHTML = html;
    };
    

    Or you can simply put your javascript code just before </body> tag with no need to use onload there.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following div: <div style=height: 200px> <a href=#>Click to View</a> </div> I
I have following code div { width: 200px; border-bottom: 1px solid magenta; height: 50px;
I have the following div and paragraphs: <div id=container> <p class=jsavoutput jsavscroll readonly=readonly style=width:225px;
I have the following div: <div class='amazingmenu' id='menupull'> <img src='images/down.png' width=20 height=20 align='right'/> <div
I have the following code: DIV><TABLE><TBODY><TR><TD> <DIV id=namesClass style=WIDTH: 700px> <UL style=MARGIN-LEFT: 0px! important;
I have the following div : <div id=new style=position: absolute; z-index: 100; top: 210px;
I have the following code: div.leftnav { overflow: auto ; height: 50% ; }
I have the following DIV <div id=products> </div> #products { height: 102px; width: 84%;
I have the following CSS: div#topWrap div#advancedSearchWrap { width:738px; border:solid 1px #dadada; background-color:#fffcd9; margin-top:4px;
Suppose I have the following DIV <div id=myDiv style=display:none title=></div> I have an ajax

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.