The AppCreate3 method creates a new Web application, configures what type of process to run it in, and assigns it to an application pool, optionally creating the application pool.
objIIsWebVirtualDir.AppCreate3( AppMode, AppPoolName, bCreate )
[in] Long integer that specifies whether the application being created is to run in-process (0), out-of-process (1), or in a pooled process (2). If the application already exists and is running, changing the value of this flag will cause the application definition to be deleted and a new application created to run in the specified process space.
[in] A string that specifies the friendly name of the application pool you want this application to be a part of.
[in] A Boolean value that specifies if you want to create the application pool if it does not already exist.
This method has no return values.
Server: Requires or Windows Server 2003.