Re: How to get around new limitations on SetForegroundWindow()?

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Alexander Grigoriev (alegr_at_earthlink.net)
Date: 03/21/04


Date: Sat, 20 Mar 2004 21:54:38 -0800

I don't quite understand your problem. Do you need to make your app window
foreground at some events? Is it user interface window?

If I understand correctly, your apps interact by simulating user input? It
is not the proper method for industrial grade app. Use other, more reliable,
IPC means, such as named pipes, DCOM, etc.

"Dean Roddey" <droddey@charmedquark.com> wrote in message
news:OBol8IvDEHA.3408@tk2msftngp13.phx.gbl...
> I have an issue that I'm not sure how to get around with setting the
> foreground window. My company is the vendor of a distributed control and
> automation product. It's concentrated on the more traditional aspects of
C&A
> so far, i.e. external device control. But I'm extending it for application
> control. But this raises a fundamental problem. The product is network
> distributed, so the bits are spread out, and among those pieces is an app
> control server programs, which is a GUI app that the user runs on any
> machines that he wants to control applications on. That server program is
a
> kind of proxy for the control system on that host, and it starts, stops,
> etc... applications based on remote commands from 'device' drivers loaded
> into various other hosts in the network (where device is an app in this
> case.)
>
> But, because of the distributed nature of the system, the user is not
> directly interacting with program that ultimately will control the app
(and
> try to feed it faked input and whatnot.) So, that server program will not
be
> the active application in most cases when commands come in. Because of the
> recent changes to foreground setting, it will not be able to bring up
> another app, that app will just blink it's task bar item and not come up.
>
> This is clearly not going to be acceptable to my users, so there has to be
a
> way around this. Clearly if a system is going to be remotely controlled,
it
> must be possible for a server program to start and stop apps and bring
them
> to the foreground as required, when that program wouldn't (under current
> rules) have the technical right to bring an app forward.
>
> So is there some way to get around this limitation? I don't see how I can
> create a useful app control system within the current limitations.
>
> ------------------------------------
> Dean Roddey
> The Charmed Quark Controller
> www.charmedquark.com
>
>



Relevant Pages

  • Re: Opinion wanted
    ... the details including the nature of my own app (which you mischaraterized ... correct the current control (provided that control is invalid but invalid ... causes you to validate controls that have already been ... largely discreditted for good reason and has very little use these days. ...
    (microsoft.public.dotnet.framework.windowsforms)
  • Re: How to get around new limitations on SetForegroundWindow()?
    ... > is not the proper method for industrial grade app. ... my system is a control and automation system. ... for a given application will connect to the proxy on the host it is told to, ... that only a current foreground app can bring other apps to the foreground. ...
    (microsoft.public.win32.programmer.ui)
  • Re: Honestly Curious
    ... Mac apps do not need this. ... you don't have to run an app at all. ... You don't have to look for the right app to uninstall, ... full control over what is being removed from your HD. ...
    (comp.sys.mac.advocacy)
  • Re: Visual Basic for Autorun?
    ... If changes are required they can't be specific to one app. ... Obviously this doesn't apply to all usercontrols and should ... everything is in the one language. ... >I've done it fairly extensively and it works quite well as long as you keep good control over it. ...
    (microsoft.public.vb.general.discussion)
  • How to get around new limitations on SetForegroundWindow()?
    ... so far, i.e. external device control. ... distributed, so the bits are spread out, and among those pieces is an app ... that server program will not be ... recent changes to foreground setting, it will not be able to bring up ...
    (microsoft.public.win32.programmer.ui)