Questions tagged [cmd]

Command Prompt (executable name cmd.exe) is the Microsoft supplied command line interpreter on OS/2, Windows CE, and all Microsoft Windows operating systems. Use this tag for questions regarding programming scripts or on commands available to run from the Command Prompt. Add tags for which version of Windows, and tags describing the task or issue.

Command Prompt (executable name cmd.exe) is the Microsoft-supplied command-line interpreter on Windows NT-based operating systems (including Windows 2000, XP, Vista, 7, 8, 10, Server 2003, Server 2008, Server 2012 and Server 2016), OS/2 and Windows CE. It is the analog of COMMAND.COM in MS-DOS and Windows 9x (where it is called MS-DOS Prompt) systems, or of the Unix shells used on Unix-like systems.

Include additional tags to identify the version of Windows such as , , , etc.

Resources:

See also:

26386 questions
6
votes
5 answers

Check if label exists cmd

I wonder is there any way to check that if a label exist in a batch file? If %input%=ABC ( If Label ABC Exists ( Goto ABC ) ) How can I do this? Any help will be appreciated.
Jamie
  • 1,096
  • 2
  • 19
  • 38
6
votes
3 answers

How do I get a for loop to work with a comma delimited string?

This is my code so far: for /f "tokens=1 eol=," %%f IN ("1,2,3,4") do ( echo . echo %%f ) I'm expecting that to produce: . 1 . 2 . etc... But instead I get: . 1 And that's it. What am I missing?
jcollum
  • 43,623
  • 55
  • 191
  • 321
6
votes
5 answers

Cordova is not recognized... immediately after installation

I'm stuck with this very frustrating problem while trying to install Apache Cordova. I issue npm install -g cordova in my cmd (Windows 8.1, 64 bits), and everything seems to be fine. But even after the installation when trying to type cordova it is…
jdfauw
  • 647
  • 3
  • 11
  • 22
6
votes
1 answer

C# code to run my installer.exe file in silent mode, in the background,

I have this C# code: string desktopPath = Environment.GetFolderPath(Environment.SpecialFolder.Desktop); ProcessStartInfo psi = new ProcessStartInfo(); psi.Arguments = "–s –v –qn"; psi.CreateNoWindow = true; psi.WindowStyle =…
Zolt
  • 2,761
  • 8
  • 43
  • 60
6
votes
3 answers

Printing out unicode from Java code issue in windows console

I have got a problem with printing out a unicode symbol in the windows console. Here's the java code that prints out the unicode symbol value; System.out.print("\u22A2 "); The problem doesn't exist when I run the program in Eclipse with encoding…
Adrian
  • 215
  • 1
  • 6
  • 14
6
votes
4 answers

How do I commit with a utf-8 message file?

I am trying to commit a revision with subversion on cmd.exe. The cmd.exe's codepage is utf-8 (set with chcp 65001): c:\path\to\work\dir> svn ci Since I have not specified a message with the -m flag, and the variable SVN_EDITOR is set to gvim, gvim…
René Nyffenegger
  • 39,402
  • 33
  • 158
  • 293
6
votes
4 answers

CMD: failure of %~d0 when CALL quotes the name of the batch file

Why the following failure of %~d0 to return the batch file's drive letter S: when CALL quotes the name of the batch file? S:\!DJ DAP>type test.bat R: %~d0 S:\!DJ DAP>call test.bat S:\!DJ DAP>R: R:\>S: S:\!DJ DAP>call "test.bat" S:\!DJ…
ChrisJJ
  • 2,191
  • 1
  • 25
  • 38
6
votes
2 answers

FORFILES date -after- (date calc in cmd file)

I'd like to use FORFILES in a cmd file, to act on all files after a given date thru "today". I can use something like forfiles /d +07/10/2013 /c "cmd /c echo @fname" to act on everything after 7/10/13, but what I want is to just be able to…
Debra
  • 197
  • 1
  • 7
6
votes
2 answers

Passing parameters to powershell script

I'm trying to run a powershell script from the run dialog (will be used as a scheduled task), and I'm having troubles passing parameters. The script will take in two parameters, named title and msg. The script is located in: D:\Tasks…
desto
  • 1,047
  • 3
  • 14
  • 19
6
votes
2 answers

How to move files with adb shell?

How can I move files with adb shell ? For example I would like to move SystemUI.apk from /system to /system/app I didn't find any command to move files inside system partition with adb shell. Do anyone know how to do this?
orglce
  • 513
  • 2
  • 7
  • 19
6
votes
1 answer

xcconfig option in xcodebuild command

I have created an app in IOS and want to build and run it through command line. The xcodebuild command helps in building the app and its basic syntax is as follows: xcodebuild -target "${TARGET_NAME}" -sdk "${TARGET_SDK}" -configuration Release…
clint
  • 1,786
  • 4
  • 34
  • 60
6
votes
1 answer

Command line does not wait until the exe execution is finished

I converted my matlab program to a standalone exe. When I call the exe from the command line it does not wait till the exe is executed. The program takes about 20-30sec to run. The program basically creates a txt file. How can I make it to wait…
user1583647
  • 1,227
  • 2
  • 24
  • 48
6
votes
4 answers

Why does batch file FOR fail when iterating over command output?

I have a batch file that uses this idiom (many times) to read a registry value into an environment variable: FOR /F "tokens=2* delims= " %%A IN ('REG QUERY "HKLM\SOFTWARE\Path\To\Key" /v ValueName') DO SET MyVariable=%%B (There's a tab character…
Tim Danner
  • 630
  • 8
  • 20
6
votes
2 answers

Windows SDK environment and powershell

The windows v7.1 SDK has a SetEnv.Cmd script in its binary folder to correctly setup its environment. The problem is this script obviously only works with cmd.exe and I can't find an equivalent for powershell anywhere. So am I forced to use cmd.exe…
Voo
  • 29,040
  • 11
  • 82
  • 156
6
votes
1 answer

How use font forge to generate a font in cmd

prompt please how to convert the ttf to svg in the utility fontforge from the command line windows, or how use api in .NET, thanks
Artem Polishchuk
  • 505
  • 5
  • 17