PDA

View Full Version : Activating a view from another view - loose focus problem



Michel Boisvert
31-Jan-2005, 10:08 AM
Hi all,

When calling some view from other views, the focus seems to stay on the
calling view (tab advance cursor on calling view, not the new view)..

What can cause this problem?

I have many views that work fines, but other that just doesn't keep the
focus.

Michel

G.Veenhof
31-Jan-2005, 10:23 AM
A view can only be activated once with activate_view.
May be the "new" view was already activated?

Regards, Geurt Veenhof

"Michel Boisvert" <ipso@qc.aira.com> schreef in bericht
news:0eQJja6BFHA.4336@dacmail.dataaccess.com...
> Hi all,
>
> When calling some view from other views, the focus seems to stay on the
> calling view (tab advance cursor on calling view, not the new view)..
>
> What can cause this problem?
>
> I have many views that work fines, but other that just doesn't keep the
> focus.
>
> Michel
>

Michel Boisvert
31-Jan-2005, 10:56 AM
No, it's the first time and all the time the problem occurs only with some
views.

Michel


"G.Veenhof" <G.Veenhof@Nefertiti.Demon.Nl> a écrit dans le message de news:
4JBjYj6BFHA.4336@dacmail.dataaccess.com...
>
> A view can only be activated once with activate_view.
> May be the "new" view was already activated?
>
> Regards, Geurt Veenhof
>
> "Michel Boisvert" <ipso@qc.aira.com> schreef in bericht
> news:0eQJja6BFHA.4336@dacmail.dataaccess.com...
>> Hi all,
>>
>> When calling some view from other views, the focus seems to stay on the
>> calling view (tab advance cursor on calling view, not the new view)..
>>
>> What can cause this problem?
>>
>> I have many views that work fines, but other that just doesn't keep the
>> focus.
>>
>> Michel
>>
>
>

David Martinko
31-Jan-2005, 11:02 AM
You must have code being executed after the activate. If the called view is
not modal, then the code following the Activate_View will be run.


Procedure OnClick
Send Activate_MyView_vw // popup view
Send Activate of oForm1 // changes focus to first form so MyView loses
focus
End_Procedure


--
David Martinko
Redeemed Software
248-535-7495
RedeemedSoftware(SHIFT+2)Hotmail(PERIOD)com


"Michel Boisvert" <ipso@qc.aira.com> wrote in message
news:Njbty16BFHA.4336@dacmail.dataaccess.com...
> No, it's the first time and all the time the problem occurs only with some
> views.
>
> Michel
>
>
> "G.Veenhof" <G.Veenhof@Nefertiti.Demon.Nl> a écrit dans le message de
> news: 4JBjYj6BFHA.4336@dacmail.dataaccess.com...
>>
>> A view can only be activated once with activate_view.
>> May be the "new" view was already activated?
>>
>> Regards, Geurt Veenhof
>>
>> "Michel Boisvert" <ipso@qc.aira.com> schreef in bericht
>> news:0eQJja6BFHA.4336@dacmail.dataaccess.com...
>>> Hi all,
>>>
>>> When calling some view from other views, the focus seems to stay on the
>>> calling view (tab advance cursor on calling view, not the new view)..
>>>
>>> What can cause this problem?
>>>
>>> I have many views that work fines, but other that just doesn't keep the
>>> focus.
>>>
>>> Michel
>>>
>>
>>
>
>

Michel Boisvert
31-Jan-2005, 11:40 AM
Code is straight forward..

Procedure OnClick
Send activate_clilab
End_Procedure // OnClick

button is a cWinbutton and set to pointer_only. Focus stays on the calling
view, not on clilab as it should.. The caption color shows as if the called
view is focused, but if I hit the tab key, the underlying view receives the
key.. Focus changes if I click on the overlying view.


Michel


"David Martinko" <RedeemedSoftware@Hotmail.com> a écrit dans le message de
news: uuyUK56BFHA.1912@dacmail.dataaccess.com...
> You must have code being executed after the activate. If the called view
> is not modal, then the code following the Activate_View will be run.
>
>
> Procedure OnClick
> Send Activate_MyView_vw // popup view
> Send Activate of oForm1 // changes focus to first form so MyView loses
> focus
> End_Procedure
>
>
> --
> David Martinko
> Redeemed Software
> 248-535-7495
> RedeemedSoftware(SHIFT+2)Hotmail(PERIOD)com
>
>
> "Michel Boisvert" <ipso@qc.aira.com> wrote in message
> news:Njbty16BFHA.4336@dacmail.dataaccess.com...
>> No, it's the first time and all the time the problem occurs only with
>> some views.
>>
>> Michel
>>
>>
>> "G.Veenhof" <G.Veenhof@Nefertiti.Demon.Nl> a écrit dans le message de
>> news: 4JBjYj6BFHA.4336@dacmail.dataaccess.com...
>>>
>>> A view can only be activated once with activate_view.
>>> May be the "new" view was already activated?
>>>
>>> Regards, Geurt Veenhof
>>>
>>> "Michel Boisvert" <ipso@qc.aira.com> schreef in bericht
>>> news:0eQJja6BFHA.4336@dacmail.dataaccess.com...
>>>> Hi all,
>>>>
>>>> When calling some view from other views, the focus seems to stay on the
>>>> calling view (tab advance cursor on calling view, not the new view)..
>>>>
>>>> What can cause this problem?
>>>>
>>>> I have many views that work fines, but other that just doesn't keep the
>>>> focus.
>>>>
>>>> Michel
>>>>
>>>
>>>
>>
>>
>
>

David Martinko
31-Jan-2005, 11:55 AM
Try changing the button to a vdf button and see if the problem is in the
cWinButton... Pointer_Only is not supported (unless something changed) so
there maybe some conflict somewhere. There were several classes offered
which allow a button to be set the Pointer_Only... I think one of the
solutions was to use a toolbar button. It was a little tricky, but I made it
work the way I wanted (I also wanted the popup help of the button as well as
the transparent images).

HTH

--
David Martinko
Redeemed Software
248-535-7495
RedeemedSoftware(SHIFT+2)Hotmail(PERIOD)com

"Michel Boisvert" <ipso@qc.aira.com> wrote in message
news:hOT2AO7BFHA.4336@dacmail.dataaccess.com...
> Code is straight forward..
>
> Procedure OnClick
> Send activate_clilab
> End_Procedure // OnClick
>
> button is a cWinbutton and set to pointer_only. Focus stays on the
> calling view, not on clilab as it should.. The caption color shows as if
> the called view is focused, but if I hit the tab key, the underlying view
> receives the key.. Focus changes if I click on the overlying view.
>
>
> Michel
>
>
> "David Martinko" <RedeemedSoftware@Hotmail.com> a écrit dans le message de
> news: uuyUK56BFHA.1912@dacmail.dataaccess.com...
>> You must have code being executed after the activate. If the called view
>> is not modal, then the code following the Activate_View will be run.
>>
>>
>> Procedure OnClick
>> Send Activate_MyView_vw // popup view
>> Send Activate of oForm1 // changes focus to first form so MyView loses
>> focus
>> End_Procedure
>>
>>
>> --
>> David Martinko
>> Redeemed Software
>> 248-535-7495
>> RedeemedSoftware(SHIFT+2)Hotmail(PERIOD)com
>>
>>
>> "Michel Boisvert" <ipso@qc.aira.com> wrote in message
>> news:Njbty16BFHA.4336@dacmail.dataaccess.com...
>>> No, it's the first time and all the time the problem occurs only with
>>> some views.
>>>
>>> Michel
>>>
>>>
>>> "G.Veenhof" <G.Veenhof@Nefertiti.Demon.Nl> a écrit dans le message de
>>> news: 4JBjYj6BFHA.4336@dacmail.dataaccess.com...
>>>>
>>>> A view can only be activated once with activate_view.
>>>> May be the "new" view was already activated?
>>>>
>>>> Regards, Geurt Veenhof
>>>>
>>>> "Michel Boisvert" <ipso@qc.aira.com> schreef in bericht
>>>> news:0eQJja6BFHA.4336@dacmail.dataaccess.com...
>>>>> Hi all,
>>>>>
>>>>> When calling some view from other views, the focus seems to stay on
>>>>> the calling view (tab advance cursor on calling view, not the new
>>>>> view)..
>>>>>
>>>>> What can cause this problem?
>>>>>
>>>>> I have many views that work fines, but other that just doesn't keep
>>>>> the focus.
>>>>>
>>>>> Michel
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>