[AccessD] DoCmd.OpenFrom acHidden is not hidden

Salakhetdinov Shamil mcp2004 at mail.ru
Fri Mar 15 05:18:25 CDT 2013


 Gustav --

Additionally: using Form's Timer event to make calculations and to call SetVisible() should help to solve your issue I suppose.

Thank you.

-- Shamil


Пятница, 15 марта 2013, 13:18 +04:00 от Salakhetdinov Shamil <mcp2004 at mail.ru>:
>Hi Gustav --
>
>If your calling/parent form doesn't have any special attributes set, IOW it's opened in a Normal form view, with no popup or modal modes 'On' then I'd guess that your
>
>=SetVisible()
>
>call of the child form's hidden textbox somehow 'weirdly interacts' with acHidden argument of  the executing call
>
>  DoCmd.OpenForm "frmSomeForm", acNormal , , , , acHidden
>
>I mean =SetVisible() could be called *before* Form Open event, and while being called it forces its form to start to be rendered but here acHidden argument comes into play...
>
>I'd try to call SetVisible() in the form Open event
>
>Me.MySoFarInvisbleTextBox.Visible = SetVisible()
>
>Why do you use so unusual(?) way to make your form visible via an indirect call to the SetVisible() function?
>
>Thank you.
>
>-- Shamil
>
>Пятница, 15 марта 2013, 9:31 +01:00 от "Gustav Brock" < gustav at cactus.dk >:
>>Hi all
>>
>>From a form I try to open another form hidden by clicking a button:
>>
>>  DoCmd.OpenForm "frmSomeForm", acNormal , , , , acHidden
>>
>>Then the hidden form is supposed to do some calculations and, when finished,
>>unhide itself by means of a not visible textbox bound to a function:
>>
>>  =SetVisible()
>>
>>which contains:
>>
>>Private Function SetVisible() As Boolean 
>>    Me.Visible = True 
>>    SetVisible = True 
>>End Function
>>
>>The sequence works except for one thing - the form isn't opened hidden
>>because its frame is shown at once.
>>Thus, the sequence is:
>>
>>1. Frame of hidden form is shown on top of the calling form. The form itself
>>is transparent so the calling form is still visible inside the frame.
>>2. The "hidden" form performs the calculations.
>>3. The "hidden" form paints its inside invisibly.
>>4. SetVisible is called.
>>5. The completed form is visible.
>>
>>I've also tried opening the hidden form with:
>>
>>  Set frm = New Form_frmSomeForm
>>  frm. Visible = False
>>
>>No difference. Also having this in the OnOpen event of the form:
>>
>>  Me.Visible = False
>>
>>All to no avail.
>>
>>Any ideas for opening a form completely hidden?
>>
>>/gustav
>>


More information about the AccessD mailing list