Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Run without Dos box
Message
General information
Forum:
Visual FoxPro
Category:
FoxPro 2.x
Miscellaneous
Thread ID:
00139702
Message ID:
00140852
Views:
21
>>>I remember seeing a technique for doing a RUN command without seeing the DOS window pop up.
>>>I want to synchronise a client pc to the NT server using
>>>
run /n net time \\server /yes
>>>but not see the box.
>>>BTW, is there another way of doing this seemlessly?
>>
>>Hi David,
>>
>>Why not use NetRemoteTOD() API function?
>
>
>I have done this in FPW2.6 - Run a dos app without the DOS window popping up. I got the idea from a VBasic help tips&Tricks file. It is buired somewhere and will dig it out. Basically you need to run the dos program with a special .pif and from FPW using foxtools call the API SHOWWINDOW with the parameter HIDE. I will delve deep and come up with it if you still need it.
>
Hi Bernard,

Fortunately, ShowWindow() is part of the 16 bit API. FindWindow(), or another routine to return window handle will also come into play. However, and I can't check this right now, it might be easier to use ShellExecute(), passing it the name of a link file. In general, these have replaced the old pif files under 32 bit Windows. The only question, in my mind is, will 16 bit ShellExecute() do what it's supposed to. The reason I'd recommend it is that the window state is a parameter, and this would remove the necessity to get the window handle.
George

Ubi caritas et amor, deus ibi est
Previous
Reply
Map
View

Click here to load this message in the networking platform