If you have access to this window, you can use appcmd.exe:
C:\dev>\windows\system32\inetsrv\appcmd.exe apppool /?
Administration of application pools
APPCMD (command) APPPOOL <identifier> <-parameter1:value1 ...>
Supported commands:
list List application pools
set Configure application pool
add Add new application pool
delete Delete application pool
start Start application pool
stop Stop application pool
recycle Recycle application pool
(To get help for each command use /?, e.g. 'appcmd.exe add site /?'.)
, System.Diagnostics.Process .