>Hi,
>
>I have a small VFP6 App that does some database maintainence that I would like to run concurrently with my main VFP6 app. But I would like it to run in the background and not be shown on the Taskbar if possible. This is a VFP app with which the user has no interaction.
>
>Basically I want to run two copies of VFP runtime while displaying only one on the Taskbar.
>
>Does anyone know if there is a way to do this ?
Yes - embed a CONFIG.FPW in the second app with
SCREEN = OFF and never do a _SCREEN.Show() or _SCREEN.Visible = .t.; however, you'll have a great deal of difficulty cleanly stopping the app (or knowing if it hung with an error), since the only access tot he application if it needs to be checked or stopped is via Task manager, and the shutdown of a VFP app running hidden will never be clean (it'll end up doing a TerminateProcess(), which can leave data files in damaged states with data left in buffers buffers, and can also definitely leave any DLLs it references in an inconsistent state. See the MSDN Platform SDK docs on
TerminateProcess for the gory details.
>
>Is this a bad idea ?
IMO, yes, if there's any chance that the application might hang or that someone might try restarting Windows while unaware that the second app was running.
I'd strongly recommend that you change the caption and run the second instance minimized, giving the user and VFP's Event processing a chance to know that something is still running before they try to shut down Windows. A hidden VFP app won't identify itself during shutdown, and your user will be confronted with something that "didn't respond" during Windows shutdown.