Hi,
I have noticed that controls that I set .visible = .T. or .F., or controls that are resized, go through some sort of animation in the page - expanding or contracting.
While this is cool for some things, it isn't appropriate for things that are hidden at runtime.
For example, in the Init of a form I hide some controls and in the browser I see those controls starting as visible and then vanishing after their animation.
How do I turn that off? Can I turn it off only for certain events (e.g. visible = .F.)?
Thanks
Paul
Sure, see properties .wuEffectHide
and .wuEffectShow
on all visual controls.
For controls you want to always hide in web mode, you should do:
procedure Init
…
this.Visible = wlLAN() && for a class: use a function because thisForm may not be in scope
this.Visible = thisForm.wlLAN && for an instance
wcPropSaveEdit(this, 'Visible', .T.) && remove 'Visible' to make sure this control never shows up
…
return dodefault()
this way the control will be generated with style="display:none;"
and will not show up for the brief delay until the page is fully initialised.