Hi Robert,
You are correct that Form:Ready does not fire when rendering in HTML.
A possible cause for your issue is that, unlike PDF rendering, not all objects that are in your form at design time will be rendered in HTML.
By this, not only do I mean that the object is not visible, but that the object will not exist in the browser context.
Attempting to access such an object, including its presence attribute, would cause the error message that you posted.
Please see below for a non-exhaustive list of scenarios where an object is not rendered in HTML:
- Object's Presence is set to 'Hidden' at design time
- Any subform's Presence from the object up through the hierarchy to the root is set to 'Hidden' at design time
- Object is not contained by a Body Page in your hierarchy
- Object is a Script Object
Please note:
- An object with Presence set to 'Invisible' at design time is rendered in HTML (although it will not be visible)
- Once an object is rendered in HTML, it can have its presence attribute manipulated by client-side script through all states, including 'hidden'. This behaviour is consistent with PDF.
Ben
http://www.avoka.com