To start an application pool, we use the following syntax. appcmd start apppool /apppool.name: string. where the parameter string is the name of the application pool that we need to stop. Now let's execute the batch file ( StartAppPool.bat) and the result is as under. As a final activity, we need to write a C# code to invoke the batch program. IIS:\ drive provider vs. CmdLets. Retry, retry, retry. Examples. Creating sites (simple) Creating sites (advanced) Creating applications in virtual directories. Creating application pools. Assigning application pools. Check whether sites, virtual directories, or application pools already exist.