What's on top or an alternative  
Author Message
rauschi





PostPosted: Fri Mar 02 15:16:08 CST 2007 Top

Exchange Servers >> What's on top or an alternative

Hello and thanks in advance for the help.

I have form with three controls, An RTF control (TE), a grid, and a button.

Under ordinary conditions the grid and the button are invisible. Sometimes,
the grid and the button need to become active and visible.

The problem that I'm gaving is that when I issue the command

thisform.SendToGrid.visible = .t.

the grid becomes visible under the RTF control. I can't find anything that
relates to which control on a form is on top when two controls overlap.

I am using the grid and button to serve as a multiple selection menu (a menu
where more than one item can be selected). If anyone has a better idea about
how to do this please tell me.

Meanwhile, if anyone knows how to control which controls are on top, please
tell me. My existing code works if I issue thisform.RTF.visible =.f. but I
would like to have the RTF visible when the grid and button are displayed.

Thanks again,
Jeff

Exchange Server22  
 
 
Jack





PostPosted: Fri Mar 02 15:16:08 CST 2007 Top

Exchange Servers >> What's on top or an alternative


>Hello and thanks in advance for the help.
>
>I have form with three controls, An RTF control (TE), a grid, and a button.
>
>Under ordinary conditions the grid and the button are invisible. Sometimes,
>the grid and the button need to become active and visible.
>
>The problem that I'm gaving is that when I issue the command
>
>thisform.SendToGrid.visible = .t.
>
>the grid becomes visible under the RTF control. I can't find anything that
>relates to which control on a form is on top when two controls overlap.
>
>I am using the grid and button to serve as a multiple selection menu (a menu
>where more than one item can be selected). If anyone has a better idea about
>how to do this please tell me.
>
>Meanwhile, if anyone knows how to control which controls are on top, please
>tell me. My existing code works if I issue thisform.RTF.visible =.f. but I
>would like to have the RTF visible when the grid and button are displayed.

You control the Z order (which controls are above and below other
controls) with the ZOrder method of controls.

However, that only applies to VFP controls. VFP controls are painted
directly on the form. ActiveX controls, like the RTF control, are
separate windows. It is not possible to have a VFP control on top of
an ActiveX control.
 
 
Jeff





PostPosted: Sat Mar 03 08:04:21 CST 2007 Top

Exchange Servers >> What's on top or an alternative > However, that only applies to VFP controls. VFP controls are painted
> directly on the form. ActiveX controls, like the RTF control, are
> separate windows. It is not possible to have a VFP control on top of
> an ActiveX control.

Well then my only option, it seem, unless someone has a better idea is to
temporarily resize the Active X control, show the grid and button, then when
someone clicks on the button, make the grid and button invisible again and
put the Active X control back to its original size. Does this sound right?

Thanks


 
 
Fred





PostPosted: Sat Mar 03 13:47:14 CST 2007 Top

Exchange Servers >> What's on top or an alternative Does the ActiveX control need to still be in use when the grid and button
are visible? If not, you can hide the ActiveX control (probably use
thisform.ActiveXControl.Object.Visible=.f.) and swap which controls are
visible accordingly. If that doesn't work, you can move the ActiveX control
outside of the visible area of the form or container it's on by changing its
.Top and/or .Left properties.

--
Fred
Microsoft Visual FoxPro MVP




>> However, that only applies to VFP controls. VFP controls are painted
>> directly on the form. ActiveX controls, like the RTF control, are
>> separate windows. It is not possible to have a VFP control on top of
>> an ActiveX control.
>
> Well then my only option, it seem, unless someone has a better idea is to
> temporarily resize the Active X control, show the grid and button, then
> when someone clicks on the button, make the grid and button invisible
> again and put the Active X control back to its original size. Does this
> sound right?
>
> Thanks
>


 
 
Jeff





PostPosted: Mon Mar 05 10:53:05 CST 2007 Top

Exchange Servers >> What's on top or an alternative The ActiveX control does need to remain visible. That is the reason that
originally opted for an "on top" solution. I think changing its width
property will do the trick since the on-top idea doesn't work.

What do other people do who need a multi-selection menu?



> Does the ActiveX control need to still be in use when the grid and button
> are visible? If not, you can hide the ActiveX control (probably use
> thisform.ActiveXControl.Object.Visible=.f.) and swap which controls are
> visible accordingly. If that doesn't work, you can move the ActiveX
> control outside of the visible area of the form or container it's on by
> changing its .Top and/or .Left properties.
>
> --
> Fred
> Microsoft Visual FoxPro MVP
>
>


>>> However, that only applies to VFP controls. VFP controls are painted
>>> directly on the form. ActiveX controls, like the RTF control, are
>>> separate windows. It is not possible to have a VFP control on top of
>>> an ActiveX control.
>>
>> Well then my only option, it seem, unless someone has a better idea is to
>> temporarily resize the Active X control, show the grid and button, then
>> when someone clicks on the button, make the grid and button invisible
>> again and put the Active X control back to its original size. Does this
>> sound right?
>>
>> Thanks
>>
>
>