3.2.0

Super-Large ACTIVE.HTML.DIV Problem

Hi.

I've been trying to work with ActiveWidgets to make a textbox that changes when a button is pressed.

Anyway, I'm having a very strange problem.

<script>
var dayObject = new Active.HTML.DIV;
var dayText = "<h2>Day: " + day + "</h2>";
dayObject.setContent(dayText);
document.write(dayObject);
</script>

Assume day = 1, if that matters.

<script>
day++;
dayObject.setContent("<h2>Hi.</h2>");
alert(dayObject);
dayObject.refresh();
alert(dayObject);
</script>

This second script is called when the user presses a button. For some reason, I noticed that instead of changing the text to "Hi.", it made the entire div disappear. By adding the alerts, (which return the same value), I found that dayObject equaled "<div id = "div51"></div>".

I am quite confused by this. Why is "Hi." not appearing?

Thanks,
Jacco
Jacco
April 18,

This topic is archived.

See also:


Back to support forum