Information générale
Catégorie:
Gestionnaire d'écran & Écrans
>>>My initial impression is child forms are somewhat unruly (or maybe underdeveloped). Do you agree or disagree?
>>
>>I don't think the "unruly" -- you need to be aware of the settings that affect them. First the "parent" form would be set as ShowWindow=2 (As Top Level). Then the child windows would be ShowWindow=1 (In Top Level). The default setting is on the desktop area of VFP (ShowWindow=0) and then all the forms are "equal" even though one may be spawned from another. The AutoCenter, Left, and Right properties are relative the ShowWindow setting.
>
>I tried ShowWindow=2 for the parent window and it was a disaster, at least in the VFP development environment. Setting the Left/Right/Top/Bottom properties relative to the parent window is something I didn't try. But still there was the issue of the parent form's controls going dead after the child window was activated.
>
>IAC it's working to my satisfaction now with Sergey's suggestion of using page frames instead. Just minor tweaking needed. (Knock on wood <g>).
For you particular requirement, a child form is the wrong design -- a container (particularly a pageframe) is the best choice. I have many forms like this where objects are hidden until needed -- like a wizard form (it is a form with a pageframe whose border and tabs are hidden at runtime). The above is what a child form should do and how to accomplish that via the ShowWindow settings.
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement