blackberry / bbUI.js

BlackBerry UI look and feel JavaScript toolkit for WebWorks
Apache License 2.0
312 stars 192 forks source link

Help please #931

Closed onedeesain closed 11 years ago

onedeesain commented 11 years ago

Anyone can help me...how to make 'javascript auto set values' working?? this's my script(this methode not working) :

<script>
window.onload = function() {
    var data="just sample";
    document.getElementById('name').value=data;
};
</script>

<form name="frm_entry" method="POST" action="">
<div data-bb-type="round-panel">
    <div data-bb-type="panel-header">Entry</div>
        <div data-bb-type="label-control-container">                 
                         <div data-bb-type="row">
                <div data-bb-type="label">First Name</div>
                <input type="text" name="name" id="name" />
            </div>
           </div>
         </div>
</div>
</form>
tneil commented 11 years ago

I don't think I quite understand the question.. have you read over the information on how and when DOM is available to be manipulated via the ondomready or onscreenready events?