Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Launch App from Explorer and Focus shifts back to Explor
Message
De
06/09/2007 08:06:56
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01252535
Message ID:
01252681
Vues:
28
I'll give that a shot Chris, thanks!


>Tracy, i found what i was referring to earlier. Definately not the same thing as your problem. It was a focus issue of sorts between forms within VFP, not between VFP and the OS.
>
>We have a modal form that uses the DBI gantt chart control. On the control's BarDblClick() method, we display a modal "details" form that pertains to the bar task. Then control returns to the DBI gantt form. The problem was with the mouse getting 'lost' when controlled returned to the gantt form.
>
>
ctschedule.BarDblClick()
>
>... call to show a modal "details" form...
>... redraw or remove the bar, depending on changes...
>... then return to the DBI gantt chart form
>
>*--- there is a bug in the ctSchedule control.  when u return to the form, the
>*--- mouse is "behind the control" and u dont see it, but its there.  This command
>*--- will make it appear again.  Probably a more elegant way to do this....
>*---
>MOUSE CLICK AT -1,-1 WINDOW (WONTOP())
>
>> As long as that form is launched, the focus stays on the vfp app and specifically on the login form which is modal. However, if the user elects not to launch the form at startup that contains the activex control,
>
>Perhaps returning false from the INIT of the "when it works" form if the user elects not to launch it. (Launch it anyway but return false in the init.)
>
>
>
>
>>Actually no. :o( There are many forms that open up in the background of the app - all modeless. Then a login form launches that is modal. One of the modeless forms contains an activex control on it. As long as that form is launched, the focus stays on the vfp app and specifically on the login form which is modal. However, if the user elects not to launch the form at startup that contains the activex control, then even though the login form is modal, it displays and then focus dissappears to any other windows app or the windows desktop in la la land.
>>
>>
>>
>>>Thats vaguely familiar. ActiveX control on that form? Exontrol or Plexity control perhaps? Are u able to test the app by having it go to a menu instead of showing the form at launch?
>>>
>>>>Yes, it is a modal form too.
>>>>
>>>>
>>>>>Just to clarify, are you launching a form at app startup?
>>>>>
>>>>>>Actually it occurs when launched by the loader as well. If any other windows app is open,focus shifts to it (e.g. outlook, windows explorer). In fact, unless a form is launched inside our app which contains an activex control, focus is anyplace BUT The vfp app when it launches.
>>>>>>
>>>>>>
>>>>>>
>>>>>>>>The app is typically launched from a loader, but if it is launched directly from windows explorer, then focus shifts back to windows explorer. This should be a simple one, but I can't seem to recall how to fix it. Any ideas?
>>>>>>>
>>>>>>>An alternate approach would be to make it so your main app won't start unless it's being called from your loader:
>>>>>>>
>>>>>>>- check using PROGRAM(), SYS(16) etc.
>>>>>>>- in your main app check for absence of a parameter expected from your loader
.·*´¨)
.·`TCH
(..·*

010000110101001101101000011000010111001001110000010011110111001001000010011101010111001101110100
"When the debate is lost, slander becomes the tool of the loser." - Socrates
Vita contingit, Vive cum eo. (Life Happens, Live With it.)
"Life is not measured by the number of breaths we take, but by the moments that take our breath away." -- author unknown
"De omnibus dubitandum"
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform