Solved

bat file

Posted on 2000-05-12
1
376 Views
Last Modified: 2010-04-16
Hello
How can I find the windows dir in a *.bat file(from dos) so I can run a file?
0
Comment
Question by:ILPowerSoft
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 15

Accepted Solution

by:
simonet earned 30 total points
ID: 2804192
Use the %windir% variable.

Here's an example:

dir %windir%

start %windir%\notepad.exe


if %windir% hsa not been set, then try %winbootdir%. These variables are usually automatically set by Windows at start up.

Yours,

Alex
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is an explanation of a simple data model to help parse a JSON feed
Make the most of your online learning experience.
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
Simple Linear Regression

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question