Hacker’s Guide to Visual FoxPro
An irreverent look at how Visual FoxPro really works. Tells you the inside scoop on every command, function, property, event and method of Visual FoxPro.
A property of all COM servers, accessible via the Server object.
oServer.Instancing = nInstancing
nInstancing = oServer.Instancing
Parameter |
Value |
Meaning |
nInstancing |
0 |
Not creatable. |
1 |
Single use. |
|
2 |
Multiple use. |
A server’s instancing describes how it is used. Let’s start with the simple case—a single-use server is created when an application requests it, and is released when the application releases it. That’s easy. A multi-use server can be used by more than one application at the same time. Non-creatable instancing is the most confusing. We’ve read the documentation for several development languages and still don’t have a really good explanation for why you would want to do this. Perhaps these servers are ones that should only be turned on programmatically, but we haven’t run across a case yet.
Prior to VFP 7, the values above are correct and those in FoxPro.H wrong. You’ll want to correct them there or avoid using the file. VFP 7’s FoxPro.H file is correct.
oProject.Servers.Item[1].Instancing = 2