Microsoft
Software
Hardware
Network
Question : Javascript error in Chrome when setting innerHTML or innerText
I need to set the text on a hidden asp:textBox in javascript. The Script works fine in FF and IE but fails in Chrome. Does anyone know how to correct or work around this issue? The attached HTML when run in Chrome will give the error. Thanks
chromeError.htm
(605 bytes)
(File Type Details)
HTML to produce error
Answer : Javascript error in Chrome when setting innerHTML or innerText
You need no innerHTML, innerText.
The correct attribute name is: value
Like this:
<script language=javascript>
function loadText(txt) {
try {
var el = document.getElementById("T
ext1");
el.value = txt;
}
catch (err) {
alert(err);
}
}
</script>
Random Solutions
Insert Script from the command prompt
windows xp home blue screens with bad _system_config_info on boot up
Deselect radio button in a ColdFusion flash form?
Brightstor 12.5 Exchange Agent issue
Java SAX
window 7 OS: blank (black) screen only, as it logs in
Counting number of checked checkboxes in a form (when checkboxes are all named differently)
wpf
Windows Server 2008 DistributedCOM error in System Log
explanation of httpcontext needed