>Hi all
>
>This is my first time on the thread and I have a question.
>
>Can a VFP project that has been compiled into an .exe compile a .prg without VFP being loaded first?
>
VFP6 with SP3 introduced the ability to compile a .PRG to an .FXP for the first time from a compiled application. No earlier version incorporated the compiler into the runtime.
If you have VFP6, you need to install the SP3 update (available from msdn.microsoft.com/vfoxpro, or you can order it on CD for a nominal charge.) it's a BIG file, so I'd recommend getting it on CD from Microsoft.
If you are using an earlier version of VFP than VFP6, you don't have the option of compiling within a compiled application running under the runtime - the COMPILE command was only available under VFP development environment. Your only options are to upgrade to VFP6 SP3, or to buy a copy of the development system for each target machine, and expensive proposition.
>I have built an executable from a project that as an end result creates a .prg and runs it. This works fine until I try to run it
>on a computer without VFP loaded onto it. If VFP isn't installed
>and I add the compile .prg command to the .exe code, I get the error "feature not available." If I take the compile command out of the .exe, I get the error "'file'.prg" does not exist.
>
There are add-on interpreters like the CODEBLOCK app (downloadable from here on UT) that will run some (not all) >PRGs from raw source, but it's slower and much more limited than compilation.