A customer asked the following:
“When VFP starts wee see it’s splash screen almost immediately after the mouseclick, then it disappears when VFP is finished starting up. If I develop a splash screen in my Fox app it shows after the runtime is in memory, which takes a few miliseconds. Is it possible to show a splash screen (a bitmap/image would be good enough) immediatly after I click my Fox application and to make it disappear after my app is completely finished starting ? Thanks in advance !”
A splash screen is a window that’s displayed very early when a process initializes. When a developer creates a runtime application written in Foxpro, the splash screen that their end user sees can be customized. An image can be displayed on your runtime exectutable’s command line. You can also specify the duration. This image will be shown very early in the initialization of the VFP runtime. See How to: Use Command-Line Options When Starting Visual FoxPro
There are some limitations to the type of image that can be displayed. VFP uses GDIPlus to handle JPGs, animated GIFs, etc.. Because the VFP runtime hasn’t been fully initialized yet, GDIPlus hasn’t been initialized. Simple workaround: convert the image to a BMP.
A long time ago, VFP3 (released in 1995) had a splash screen that was WS_EX_TOPMOST which meant that it would be on top of any other window, even after alt-tab or clicking on another window underneath. That was pretty annoying, especially with a slow startup on a 386 machine.
In older versions of Foxpro, the handling of JPGs was done internally: there was actually code inside VFP5.exe to decompress a JPG file. However, as the JPG format evolved and the VFP5.exe stayed the same, there were some compatibility issues. With Windows XP, GDIPlus included routines that handled graphics. VFP takes advantage of these OS routines, so that as new graphics formats emerge, an update to GDIPlus will enable VFP to handle them. Also, GDIPlus handles many more graphic formats than VFP5 did.
One can argue that adding more functionality to the OS is a Dept of Justice monopolistic bundling issue, but then you’d have to go to law school.