You can specify pagefile location and size by modifying the PagingFiles value under the HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlSession ManagerMemory Management registry subkey. If you want the system to manage pagefile size, simply set the initial and maximum pagefile sizes to 0, as the following example shows:
C:pagefile.sys 0 0
You must reboot the machine for the change to take effect.