9

How do i tell windows to open C:\test\test.txt in WordPad, when Notepad is my default program for .txt files?

Jean-François Fabre
  • 137,073
  • 23
  • 153
  • 219
Lassa
  • 121
  • 1
  • 2
  • 5

4 Answers4

17

The accepted answer didn't work for me. I am not sure if it was because of the program I was trying to run, or because the path had spaces in (even though I wrapped it in quotes), or something else.

Anyway, I was able to do it be adding an empty string after the start command.

For example:

start "" "C:\My Programs\myprogram.exe" "C:\My Files\myfile.txt"
musefan
  • 47,875
  • 21
  • 135
  • 185
9

You can add the direct path to the executable like

start C:\Windows\System32\write.exe [FILE]
Mofi
  • 46,139
  • 17
  • 80
  • 143
corn3lius
  • 4,857
  • 2
  • 31
  • 36
2

Try:

start wordpad c:\test\test.txt
Kirk Woll
  • 76,112
  • 22
  • 180
  • 195
0

There is no need to use start when using write.exe, so simply:

write [FILE(S)]

write.exe is located in C:\Windows\System32.

double-beep
  • 5,031
  • 17
  • 33
  • 41