Windows bat file open file

I’m would like to know how I can open a specific file using a specific program with a batch file. So far, my batch file can open the program, but I’m not sure how to open a file with that program.

@echo off
start wgnuplot.exe

asked Apr 7, 2010 at 17:08

sooprise's user avatar

start wgnplot.exe "c:\path to file to open\foo.dat"

answered Apr 7, 2010 at 17:10

Chris Thornton's user avatar

Chris ThorntonChris Thornton

15.7k5 gold badges37 silver badges62 bronze badges

4

If the file that you want to open is in the same folder as your batch(.bat) file then you can simply try:

start filename.filetype

example: start image.png

CDub's user avatar

CDub

13.1k4 gold badges51 silver badges68 bronze badges

answered Nov 13, 2013 at 20:54

ASGeek's user avatar

ASGeekASGeek

511 silver badge1 bronze badge

2

@echo off
start %1

or if needed to escape the characters —

@echo off
start %%1

answered Apr 7, 2010 at 17:10

Etamar Laron's user avatar

Etamar LaronEtamar Laron

1,17210 silver badges23 bronze badges

0

you are in a situation where you cannot set a certain program as the default program to use when opening a certain type of file, I’ve found using a .bat file handy. In my case, Textpad runs on my machine via Microsoft Application Virtualization («AppV»). The path to Textpad is in an «AppV directory» so to speak. My Textpad AppV shortcut has this as a target…

%ALLUSERSPROFILE%\Microsoft\AppV\Client\Integration\
 12345ABC-A1BC-1A23-1A23-1234567E1234\Root\TextPad.exe

To associate the textpad.exe with ‘txt’ files via a ‘bat’ file:

1) In Explorer, create a new (‘txt’) file and save as opentextpad.bat in an «appropriate» location

2) In the opentextpad.bat file, type this line:

textpad.exe %1  

3) Save and Close

4) In explorer, perform windows file association by right-clicking on a ‘txt’ file (e.g. ‘dummy.txt’) and choose ‘Open with > Choose default program…’ from the menu. In the ‘Open with’ window, click ‘Browse…’, then navigate to and select your textpad.bat file. Click ‘Open’. You’ll return to the ‘Open with’ window. Make sure to check the ‘Always use the selected program to open this type of file’ checkbox. Click ‘OK’ and the window will close.

When you open a ‘txt’ file now, it will open the file with ‘textpad.exe’.

Hope this is useful.

answered Jan 28, 2015 at 17:40

Jason D.H.'s user avatar

Jason D.H.Jason D.H.

1011 silver badge2 bronze badges

That program would need to have a specific API that you can use from the command line.

For example the following command uses 7Zip to extract a zip file. This only works as 7Zip has an API to do this specific task (using the x switch).

"C:\Program Files\7-Zip\CommandLine\7za.exe" x C:\docs\base-file-structure.zip 

answered Apr 7, 2010 at 17:11

Marcus Leon's user avatar

Marcus LeonMarcus Leon

55.3k118 gold badges298 silver badges429 bronze badges

You can simply call

program "file"

from the batch file for the vast majority of programs. Don’t mess with start unless you absolutely need it; it has various weird side-effects that make your life only harder.

The The point here is that pretty much every program that does something with files allows passing the name of the file to do something with in the command line. If that weren’t the case, then you couldn’t double-click files in the graphical shell to open them, for example.

If the program you’re executing is a console application, then it will run in the current console window and the batch file will continue afterwards. If the program is a GUI program (i.e. not a console program; that’s a distinction in the EXE) then the batch file will continue immediately after starting it.

answered Apr 18, 2010 at 8:48

Joey's user avatar

JoeyJoey

345k85 gold badges690 silver badges687 bronze badges

@echo off
cd "folder directory to your file"
start filename.ext

For example:

cd "C:\Program Files (x86)\Winamp" 
Start winamp.exe

Tatsuyuki Ishi's user avatar

answered Apr 30, 2017 at 7:16

jirehpretorius's user avatar

1

If you are trying to open a file in the same directory it would be:

./PROGRAM TRYING TO OPEN
./FILE NAME/PROGRAM TRYING TO OPEN (or this)

Or, if trying to backtrack from the same directory it would be:

../PROGRAM TRYING TO OPEN
../FILE NAME/PROGRAM TRYING TO OPEN (or this)

Else, if you need a straight one from start, it would be:

(DIRECTORY TYPE)\Users\%username%\(FILE DIRECTORY)
(ex) C:\Users\ajste\Desktop\Henlo.cmd

answered Nov 4, 2017 at 16:59

Warriorfoox's user avatar

I’m would like to know how I can open a specific file using a specific program with a batch file. So far, my batch file can open the program, but I’m not sure how to open a file with that program.

@echo off
start wgnuplot.exe

asked Apr 7, 2010 at 17:08

sooprise's user avatar

start wgnplot.exe "c:\path to file to open\foo.dat"

answered Apr 7, 2010 at 17:10

Chris Thornton's user avatar

Chris ThorntonChris Thornton

15.7k5 gold badges37 silver badges62 bronze badges

4

If the file that you want to open is in the same folder as your batch(.bat) file then you can simply try:

start filename.filetype

example: start image.png

CDub's user avatar

CDub

13.1k4 gold badges51 silver badges68 bronze badges

answered Nov 13, 2013 at 20:54

ASGeek's user avatar

ASGeekASGeek

511 silver badge1 bronze badge

2

@echo off
start %1

or if needed to escape the characters —

@echo off
start %%1

answered Apr 7, 2010 at 17:10

Etamar Laron's user avatar

Etamar LaronEtamar Laron

1,17210 silver badges23 bronze badges

0

you are in a situation where you cannot set a certain program as the default program to use when opening a certain type of file, I’ve found using a .bat file handy. In my case, Textpad runs on my machine via Microsoft Application Virtualization («AppV»). The path to Textpad is in an «AppV directory» so to speak. My Textpad AppV shortcut has this as a target…

%ALLUSERSPROFILE%\Microsoft\AppV\Client\Integration\
 12345ABC-A1BC-1A23-1A23-1234567E1234\Root\TextPad.exe

To associate the textpad.exe with ‘txt’ files via a ‘bat’ file:

1) In Explorer, create a new (‘txt’) file and save as opentextpad.bat in an «appropriate» location

2) In the opentextpad.bat file, type this line:

textpad.exe %1  

3) Save and Close

4) In explorer, perform windows file association by right-clicking on a ‘txt’ file (e.g. ‘dummy.txt’) and choose ‘Open with > Choose default program…’ from the menu. In the ‘Open with’ window, click ‘Browse…’, then navigate to and select your textpad.bat file. Click ‘Open’. You’ll return to the ‘Open with’ window. Make sure to check the ‘Always use the selected program to open this type of file’ checkbox. Click ‘OK’ and the window will close.

When you open a ‘txt’ file now, it will open the file with ‘textpad.exe’.

Hope this is useful.

answered Jan 28, 2015 at 17:40

Jason D.H.'s user avatar

Jason D.H.Jason D.H.

1011 silver badge2 bronze badges

That program would need to have a specific API that you can use from the command line.

For example the following command uses 7Zip to extract a zip file. This only works as 7Zip has an API to do this specific task (using the x switch).

"C:\Program Files\7-Zip\CommandLine\7za.exe" x C:\docs\base-file-structure.zip 

answered Apr 7, 2010 at 17:11

Marcus Leon's user avatar

Marcus LeonMarcus Leon

55.3k118 gold badges298 silver badges429 bronze badges

You can simply call

program "file"

from the batch file for the vast majority of programs. Don’t mess with start unless you absolutely need it; it has various weird side-effects that make your life only harder.

The The point here is that pretty much every program that does something with files allows passing the name of the file to do something with in the command line. If that weren’t the case, then you couldn’t double-click files in the graphical shell to open them, for example.

If the program you’re executing is a console application, then it will run in the current console window and the batch file will continue afterwards. If the program is a GUI program (i.e. not a console program; that’s a distinction in the EXE) then the batch file will continue immediately after starting it.

answered Apr 18, 2010 at 8:48

Joey's user avatar

JoeyJoey

345k85 gold badges690 silver badges687 bronze badges

@echo off
cd "folder directory to your file"
start filename.ext

For example:

cd "C:\Program Files (x86)\Winamp" 
Start winamp.exe

Tatsuyuki Ishi's user avatar

answered Apr 30, 2017 at 7:16

jirehpretorius's user avatar

1

If you are trying to open a file in the same directory it would be:

./PROGRAM TRYING TO OPEN
./FILE NAME/PROGRAM TRYING TO OPEN (or this)

Or, if trying to backtrack from the same directory it would be:

../PROGRAM TRYING TO OPEN
../FILE NAME/PROGRAM TRYING TO OPEN (or this)

Else, if you need a straight one from start, it would be:

(DIRECTORY TYPE)\Users\%username%\(FILE DIRECTORY)
(ex) C:\Users\ajste\Desktop\Henlo.cmd

answered Nov 4, 2017 at 16:59

Warriorfoox's user avatar

Вы можете использовать команду start, чтобы открыть файл или папку.Команда start автоматически вызовет связанную программу, чтобы открыть файл и папку в соответствии с программой, связанной с файлом.

Вы можете использовать Блокнот, чтобы написать следующие команды, а затем изменить расширение на .bat

Открыть папку
start "" "c:\windows"

или

start exploer "c:\windows"
Вызов Word, чтобы открыть файл .doc
start "" "c:\test.doc"

или

start winword "c:\test.doc"
Вызовите Блокнот, чтобы открыть файл .txt.
start "" "c:\test.txt"

или

start notepad "c:\test.txt"

I have two files in the same folder that I’d like to run. One is a .txt file, and the other is the program shortcut to an .exe. I’d like to make a batch file in the same location to open the text file and the shortcut then close the batch file (but the text file and program remain open).

I tried this with no luck:

open "myfile.txt"
open "myshortcut.lnk"

Also didn’t work:

start "myfile.txt"
start "myshortcut.lnk"

This question is related to
command-line
batch-file
cmd
command-prompt

The answer is


I was able to figure out the solution:

start notepad "myfile.txt"
"myshortcut.lnk"
exit

This would have worked too. The first quoted pair are interpreted as a window title name in the start command.

start "" "myfile.txt"
start "" "myshortcut.lnk"

Don’t put quotes around the name of the file that you are trying to open; start "myfile.txt" opens a new command prompt with the title myfile.txt, while start myfile.txt opens myfile.txt in Notepad. There’s no easy solution in the case where you want to start a console application with a space in its file name, but for other applications, start "" "my file.txt" works.


The command-line syntax for opening a text file is:

type filename.txt

File types supported by this command include (but are not limited to): .doc, .txt, .html, .log

If the contents is too long, you can add «|more» after «type filename.txt», and it will pause after each screen; to end the command before the end of the file, you can hold Ctrl + C.


I use

@echo off
Start notepad "filename.txt"
exit

to open the file.

Another example is

@echo off
start chrome "filename.html"
pause

You can also do:

start notepad "C:\Users\kemp\INSTALL\Text1.txt"

The C:\Users\kemp\Install\ is your PATH. The Text1.txt is the FILE.


«location of notepad file» > notepad Filename

C:\Users\Desktop\Anaconda> notepad myfile

works for me! :)


If you are trying to open an application such as Chrome or Microsoft Word use this:

@echo off
start "__App_Name__" "__App_Path__.exe"

And repeat this for all of the applications you want to open.

P.S.: This will open the applications you select at once so don’t insert too many.


In some cases, when opening a LNK file it is expecting the end of the application run.

In such cases it is better to use the following syntax (so you do not have to wait the end of the application):

START /B /I "MyTitleApp" "myshortcut.lnk"

To open a TXT file can be in the way already indicated (because notepad.exxe not interrupt the execution of the start command)

START notepad "myfile.txt"

The command start [filename] opened the file in my default text editor.

This command also worked for opening a non-.txt file.


Try using:

@ECHO off
ECHO Hello World!

START /MAX D:\SA\pro\hello.txt

Its very simple,
1)Just go on directory where the file us stored
2)then enter command i.e. type filename.file_extention
e.g type MyFile.tx


Questions with command-line tag:

Git is not working after macOS Update (xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools)
Flutter command not found
Angular — ng: command not found
how to run python files in windows command prompt?
How to run .NET Core console app from the command line
Copy Paste in Bash on Ubuntu on Windows
How to find which version of TensorFlow is installed in my system?
How to install JQ on Mac by command-line?
Python not working in the command line of git bash
Run function in script from command line (Node JS)
How can I pass variable to ansible playbook in the command line?
Postgres «psql not recognized as an internal or external command»
How to call VS Code Editor from terminal / command line
7-Zip command to create and extract a password-protected ZIP file on Windows?
List file using ls command in Linux with full path
Find Process Name by its Process ID
How to resolve «gpg: command not found» error during RVM installation?
How to run .sh on Windows Command Prompt?
maven command line how to point to a specific settings.xml for a single command?
Run Executable from Powershell script with parameters
Running CMD command in PowerShell
Command Prompt Error ‘C:\Program’ is not recognized as an internal or external command, operable program or batch file
Build Android Studio app via command line
‘ssh’ is not recognized as an internal or external command
Input from the keyboard in command line application
How to force ‘cp’ to overwrite directory instead of creating another one inside?
Use Robocopy to copy only changed files?
Change mysql user password using command line
mkdir’s «-p» option
Shell Script: How to write a string to file and to stdout on console?
Enter export password to generate a P12 certificate
Launch Pycharm from command line (terminal)
Difference between IISRESET and IIS Stop-Start command
How can I find out if I have Xcode commandline tools installed?
Increment variable value by 1 ( shell programming)
phpmyadmin #1045 Cannot log in to the MySQL server. after installing mysql command line client
Number of processors/cores in command line
How to merge 2 JSON objects from 2 files using jq?
Displaying output of a remote command with Ansible
How do I restart nginx only after the configuration test was successful on Ubuntu?
How can I get the current date and time in the terminal and set a custom command in the terminal for it?
Run a JAR file from the command line and specify classpath
Run R script from command line
How to zip a file using cmd line?
How to switch between python 2.7 to python 3 from command line?
One command to create a directory and file inside it linux command
How to find the mysql data directory from command line in windows
Execute a command in command prompt using excel VBA
how to change directory using Windows command line
How do I import an SQL file using the command line in MySQL?

Questions with batch-file tag:

‘ls’ is not recognized as an internal or external command, operable program or batch file
» is not recognized as an internal or external command, operable program or batch file
XCOPY: Overwrite all without prompt in BATCH
Can´t run .bat file under windows 10
Execute a batch file on a remote PC using a batch file on local PC
Windows batch — concatenate multiple text files into one
How do I create a shortcut via command-line in Windows?
Getting Error:JRE_HOME variable is not defined correctly when trying to run startup.bat of Apache-Tomcat
Curl not recognized as an internal or external command, operable program or batch file
Best way to script remote SSH commands in Batch (Windows)
Create a batch file to run an .exe with an additional parameter
What does /p mean in set /p?
Find Process Name by its Process ID
Open a Web Page in a Windows Batch FIle
Batch — If, ElseIf, Else
Split text file into smaller multiple text file using command line
Batch script to install MSI
How to ping a server only once from within a batch file?
Command Prompt Error ‘C:\Program’ is not recognized as an internal or external command, operable program or batch file
Difference between xcopy and robocopy
«if not exist» command in batch file
Using a batch to copy from network drive to C: or D: drive
Split string with string as delimiter
BAT file to map to network drive without running as admin
Batch File; List files in directory, only filenames?
Run exe file with parameters in a batch file
Batch script to find and replace a string in text file within a minute for files up to 12 MB
Batch script to find and replace a string in text file without creating an extra output file for storing the modified file
How to solve «The directory is not empty» error when running rmdir command in a batch script?
«npm config set registry https://registry.npmjs.org/» is not working in windows bat file
Difference between IISRESET and IIS Stop-Start command
How to directly execute SQL query in C#?
creating batch script to unzip a file without additional zip tools
How to increment variable under DOS?
Set windows environment variables with a batch file
Executing set of SQL queries using batch file?
Create a txt file using batch file in a specific folder
Run Batch File On Start-up
Checking if a folder exists using a .bat file
Open a URL without using a browser from a batch file
Echo a blank (empty) line to the console from a Windows batch file
Safest way to run BAT file from Powershell script
Batch file to split .csv file
‘adb’ is not recognized as an internal or external command, operable program or batch file
Batch file script to zip files
Redirecting Output from within Batch file
How do I launch a Git Bash window with particular working directory using a script?
How to print the current time in a Batch-File?
How can I use a batch file to write to a text file?
Finding modified date of a file/folder

Questions with cmd tag:

‘ls’ is not recognized as an internal or external command, operable program or batch file
» is not recognized as an internal or external command, operable program or batch file
XCOPY: Overwrite all without prompt in BATCH
VSCode Change Default Terminal
How to install pandas from pip on windows cmd?
‘ls’ in CMD on Windows is not recognized
Command to run a .bat file
VMware Workstation and Device/Credential Guard are not compatible
How do I kill the process currently using a port on localhost in Windows?
how to run python files in windows command prompt?
CMD (command prompt) can’t go to the desktop
NPM stuck giving the same error EISDIR: Illegal operation on a directory, read at error (native)
What is the reason for the error message «System cannot find the path specified»?
Execute a batch file on a remote PC using a batch file on local PC
How to split large text file in windows?
PHP is not recognized as an internal or external command in command prompt
Change directory in Node.js command prompt
How to disable Hyper-V in command line?
How do I create a shortcut via command-line in Windows?
Windows equivalent of ‘touch’ (i.e. the node.js way to create an index.html)
How to run Pip commands from CMD
Curl not recognized as an internal or external command, operable program or batch file
Windows CMD command for accessing usb?
Create a batch file to run an .exe with an additional parameter
Find Process Name by its Process ID
Set proxy through windows command line including login parameters
Open a Web Page in a Windows Batch FIle
find path of current folder — cmd
Can’t check signature: public key not found
Running CMD command in PowerShell
Ping with timestamp on Windows CLI
The filename, directory name, or volume label syntax is incorrect inside batch
PowerShell The term is not recognized as cmdlet function script file or operable program
«if not exist» command in batch file
Windows 7 — ‘make’ is not recognized as an internal or external command, operable program or batch file
Using a batch to copy from network drive to C: or D: drive
Split string with string as delimiter
«Could not find or load main class» Error while running java program using cmd prompt
Find Number of CPUs and Cores per CPU using Command Prompt
Set windows environment variables with a batch file
Executing set of SQL queries using batch file?
CMD what does /im (taskkill)?
How to run a command in the background on Windows?
How to run different python versions in cmd
Open a URL without using a browser from a batch file
How to fix ‘.’ is not an internal or external command error
Redirecting Output from within Batch file
UTF-8 in Windows 7 CMD
How to copy a folder via cmd?
Basic text editor in command prompt?

Questions with command-prompt tag:

CMD command to check connected USB devices
How do I kill the process currently using a port on localhost in Windows?
PowerShell The term is not recognized as cmdlet function script file or operable program
open program minimized via command prompt
How to connect to SQL Server from command prompt with Windows authentication
How to see the proxy settings on windows?
How do I type a TAB character in PowerShell?
Batch file to split .csv file
Aliases in Windows command prompt
Change all files and folders permissions of a directory to 644/755
How to use passive FTP mode in Windows command prompt?
How can I set / change DNS using the command-prompt at windows 8
How to zip a file using cmd line?
how to change directory using Windows command line
How to complete the RUNAS command in one line
Run Command Line & Command From VBS
How to start jenkins on different port rather than 8080 using command prompt in Windows?
Server is already running in Rails
Start/Stop and Restart Jenkins service on Windows
How do I use a pipe to redirect the output of one command to the input of another?
Opening Chrome From Command Line
How to get all Windows service names starting with a common word?
How to connect from windows command prompt to mysql command line
How do I run a program from command prompt as a different user and as an admin
Messages Using Command prompt in Windows 7
Command line for looking at specific port
How to run Java program in command prompt
How to run TestNG from command line
Command prompt won’t change directory to another drive
Run a Command Prompt command from Desktop Shortcut
How to include jar files with java file and compile in command prompt
How do I minimize the command prompt from my bat file
What is the alternative for ~ (user’s home directory) on Windows command prompt?
Get CPU Usage from Windows Command Prompt
How to run an application as «run as administrator» from the command prompt?
Install a Windows service using a Windows command prompt?
how concatenate two variables in batch script?
javac is not recognized as an internal or external command, operable program or batch file
How to add a set path only for that batch file executing?
Prevent overwriting a file using cmd if exist
Open text file and program shortcut in a Windows batch file
How to change current working directory using a batch file
Changing default startup directory for command prompt in Windows 7
How can I move all the files from one folder to another using the command line?
‘git’ is not recognized as an internal or external command
Have bash script answer interactive prompts
xcopy file, rename, suppress «Does xxx specify a file name…» message
How to grant permission to users for a directory using command line in Windows?
javac not working in windows command prompt
batch file Copy files with certain extensions from multiple directories into one directory

On Mac OS X and GNOME on Linux, there are commands that can be used to open files from the command line in their associated GUI editors: open and gnome-open, respectively. Is there any command like this for Windows?

asked Feb 17, 2011 at 2:30

Wuffers's user avatar

4

If you are currently in the command prompt and have a file called test.png and , which are located in c:\test you can do the following:

If you are at the directory (so should say c:\test>) just type:

test.png

which would open test in the default png picture editor.

If the files name contains spaces, then simply enclose the file name within » «

 "this image.png"

You can alternatively type:

c:\test\test.png

which will open the file no matter where you currently are.

Finally, you can pass the picture to another program. For example, if you have an image editor called imageedit.exe and it supports opening files through command lines (and if the program is pathed/accessible or you are in it’s current directory), you can type the following:

 imageedit c:\test\test.png

Community's user avatar

answered Feb 17, 2011 at 2:38

William Hilsum's user avatar

William HilsumWilliam Hilsum

117k19 gold badges182 silver badges266 bronze badges

4

If it is a registered extension, you can use «start» as in

start WordDoc.doc

Tamara Wijsman's user avatar

answered Feb 17, 2011 at 2:36

Dennis's user avatar

DennisDennis

6,5881 gold badge28 silver badges28 bronze badges

5

On Windows command-line explorer "<PATH>" will open the file path with Windows default associated programs. This will also handle all URIs ( http:,https:,ftp: ) and other file protocols defined in Windows Operating System.
If the file or protocol is not associated with any program then an Open With dialog will show up. If file is not present then default My Documents folder will open up. It can also open executable files ( EXE, BAT files) and shell namespace paths.

Examples

explorer "http://www.google.com"— will open http://www.google.com in windows default browser.

explorer "file:///C:\temp\" will open temp directory if present

explorer "file.txt" will open file.txt on the current directory path .i.e. %CD% path

explorer ::{645ff040-5081-101b-9f08-00aa002f954e} will open RecycleBin.

You can refer about explorer’s other useful command-line switches here

oldherl's user avatar

oldherl

2031 silver badge8 bronze badges

answered Jul 7, 2017 at 18:17

lalthomas's user avatar

lalthomaslalthomas

3172 silver badges9 bronze badges

The first parameter of Start is a window title, so if you have a space in the file name, and you type

Start «My File.txt»

you’ll get a command line window with «My File.txt» as the title. To get around this use a dummy title,

Start «my title» «My File.txt»

Depending on the file and what application is opened there probably won’t be a window to see anyway.

answered Jan 27, 2017 at 14:27

Steven Digby's user avatar

1

If you are in PowerShell
(at the PS (current-directory)>  prompt),
and you want to open a file in the current directory,
you may try this .\myfile.ext
If you are in the Command Prompt, you can accomplish the same result by typing

powershell -c .\myfile.ext

(You must include the .\,
as PowerShell doesn’t load files from the current location by default.) 
Or you can provide a directory name (relative or absolute)
if the file isn’t in the current directory.

For the first scenario — if you are in PowerShell —
if the filename contains space(s),
enclose it in quotes (either kind) and precede it with
the & symbol:

PS C:\Users\myusername\Pictures> &".\funny cat.jpg"

(You may add a space after the & for readability,
if you prefer readability, and you may use / instead of \.) 
I don’t know how to make this work in the second scenario
(in which you are running powershell -c from Command Prompt)
if the file or directory name contains space(s) — quotes don’t seem to help.

Scott - Слава Україні's user avatar

answered Oct 19, 2018 at 14:25

andrey.shedko's user avatar

0

This may come a bit late, but the correct command for editing a file name in Windows 7 is «write file_name»

This should open up the default text editor and you should be able to edit the file easily

Edit: It seems to open only Wordpad. For me that was the default text editor.

answered Jul 31, 2014 at 18:11

Coder's user avatar

CoderCoder

12 bronze badges

3

Specific executable with specific file:

Git Bash Script On Windows 10 :


SHORTCUTS_MAIN_START.sh :

    FILE_PATH="C:\DEV\REPO\GIT\AHK03\SHORTCUTS\SHORTCUTS_MAIN.ahk"
    EXEC_PATH="C:\DEV\REPO\GIT\AHK03\AHK_ROOT\AutoHotkeyU64.exe"

    $EXEC_PATH $FILE_PATH

This example opens the file denoted by $FILE_PATH with the executable denoted by $EXEC_PATH. If this doesn’t work for you, try converting the single slash ( «\» ) into double slashes ( «\\» ) for the paths.

Community's user avatar

answered Sep 19, 2017 at 16:16

KANJICODER's user avatar

KANJICODERKANJICODER

3573 silver badges6 bronze badges

In the Windows command prompt, you can run

edit [file_name]

in order to view batch files/logs/text files etc. This command requires QBASIC.EXE, which is by default present in Windows.

See here for other useful MS-DOS commands.

Dave's user avatar

Dave

25.3k10 gold badges58 silver badges70 bronze badges

answered Sep 10, 2012 at 6:54

Ph03nIX's user avatar

3

You must log in to answer this question.

Not the answer you’re looking for? Browse other questions tagged

.

  • Windows automated installation kit for windows 7 что это
  • Windows bat file create file
  • Windows admin center скачать msi
  • Windows always on top windows 10
  • Windows bash python command not found