问题描述:

I found PowerCmd. And would like to substiture cmd - as default IDE for execution of bat files.

But simple replacin of comspec do nothing.

I cann't also rename cmd.exe in %SYSTEM32%.

Is possible to substiture or not?

Thanks.

网友答案:

I am giving answer for Powershell, should be similar for anything else that you want to use:

Use Regedit and goto

HKEY_CLASSES_ROOT\batfile\shell\open\command

Set the default value to

C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -noexit "%1" %*

Now when you double click on any batch file, it should run on powershell. -noexit gets to the powershell prompt after completion of the batch file.

相关阅读:
Top