cmd.exe

is there a way to move folder to trash using cmd.exe or powershell?

is there a way to move a folder to trash using cmd.exe? (Windows Vista) (that is, the behavior should be identical to user moved the folder to trash from GUI) is there a way to do it using PowerShell? ...

What parameters will allow Ghostscript to read font names in Chinese correctly from a PDF?

I tried gswin32c -sDEVICE=jpeg -sOutputFile=foo.jpg foo.pdf but I get the ff. output from Ghostscript on the page where the Chinese font is used. Substituting CID font resource/Adobe-CNS1 for /·s²Ó©úÅé. Error: /undefinedresource in --findresource-- Operand stack: --dict:4/4(L)-- F3 12.96 --dict:6/6(L)-- --dict:6/6(L)-- ·...

Windows Server 2003 64 bit cmd.exe error

I'm having trouble calling the Microsoft Cabinet Maker utility (makecab) from a batch script on a Windows Server 2003 server. The batch script is being run by Hudson (continuous integration service) installed as a windows service on the machine. The hudson.exe (64-bit) process spawns a java.exe (32-bit) process, which spawns a cmd.exe ...

Reading empty values in "for" command in a windows batch file

I have a question with the "for" batch command in windows. I have a file called keys.txt which contains this line.. key,value,x86,windows7 I want to parse this line and store the 4 comma seperated variables in 4 variables. I accomplish that by the following windows batch script. for /F "tokens=1,2,3,4* delims=," %%i in (keys.tx...

Launching a website via windows commandline

I have a program launching a website via the following command. cmd "start /max http://url.com" When launching a website via this method it uses the default browser with its default settings for opening a new window. for example, firefox and IE will open the window inside the tab of an existing window if they are set to do so. I hav...

Reading Batch shell script output into C# .Net Programm,

Good Day, As a project I am building a new front end for an old Batch script System. I have to use Windows XP and C# with .Net. I don't want to touch this old Backend system as it's crafted over the past Decade. So my Idea is to start the cmd.exe Programm and execute the Bash script in there. For this I will use the "system" function in...

Annoyance when running scripts in Vim (Windows, Ruby)

Hi, I started using vim for my programming projects (mostly Ruby) and mostly everything works just as I want but I have a problem with compiling. Lets say I am working on a Ruby script and I want to run it. I type :ruby sometging.rb (mapped to some other key). Then vim opens a new cmd.exe window and runs 'ruby something.rb'. Then it w...

How do I create batch file to rename large number of files in a folder?

I'd like to rename a large number of files within a folder on a WinXP system, preferably using a batch file. The files are currently named like this: Vacation2010 001.jpg Vacation2010 002.jpg Vacation2010 003.jpg And I'd like to change them to: December 001.jpg December 002.jpg December 003.jpg How can I perform this...

How to avoid cmd.exe interpreting shell special characters like < > ^

I have a Windows CMD script that accepts a number of parameters and executes an EXE, passing first some hard-coded arguments and then all of the parameters from the user. The CMD script looks like this: launcher.exe paramX paramY %* The user would execute the CMD script from the Windows shell as follows: launcher.cmd param1 param2 pa...

C# program parameters from the command line?

I'm trying to start a C# program running, and then give it command from the cmd.exe after it's started running. For instance, suppose I started my .exe from the command line (C://FILEPATH/my_program.exe). I'd then like to have that program continue running, and then have me be able to pass commands to it that it is capable of handling....

system() to c++ without calling cmd.exe

how can I run system("") without showing cmd.exe? I use cstdlib header code::blocks 10.5 I saw this question for c# but I don't know c# ;) ...

AIR - Batch File As CMD.exe Argument

AIR doesn't permit launching .bat files as a native process directly, so apparently i'm suppose to set CMD.exe as my startupInfo executable and pass my .bat file and it's arguments. i can't get it to work, so i'm hoping it's a syntax problem. here is my code: var testStartupInfo:NativeProcessStartupInfo = new NativeProcessStartupInfo(...

How to either create a filesystem filepath alias/redirect or rename several (xml) files to point to a new path via a programmatic text replace?

Forgive me if this is obvious but- is there any way to set up a filepath alias in Windows? I have a bunch of custom app config files that exist in a certain location and they contain filepath references to paths which I am trying to get rid of. I want to move the files referenced in these configs to a completely different file system pa...

Continue capturing output after redirection

Okay, here's a toughie-- I'm capturing the output of cmd.exe just fine, reading from the pipe, yadda yadda yadda, but then a line in the cmd.exe batch file has the audacity to do: dir err.txt >zz .. that is, it's redirecting the output of the dir command, which is an internal command inside cmd.exe. Problem is, this breaks my captu...

How to control cmd-window in win32 from Ada-code?

Hi to all. I've made a simple Lua-execution in Ada, it cooly run everything I need via Lua.Load_Buffer("os.execute('wxlua.exe wx.lua')") but I don't need win32 cmd.exe-window, which is default opens on program's start-up. Is there any way to control this event directly from Ada? P.S. os.execute() sends commands directly to Windows, not...

Why does only the first line of this Windows batch file execute but all three lines execute in a DOS command shell?

I have a batch file that executes three Maven commands, one after the other. Each command can be successfully executed in the script - by itself!. But when I add all three commands to the same file, only the first one executes before the script exits. Any idea why? mvn install:install-file -DgroupId=gdata -DartifactId=base -Dversion=1.0...

Why do I have to explicitly add perl before the script for getops to run properly?

When i run my script like so: C:\>perl script.pl -f file It works fine. But, if I just do: C:\>script.pl -f file then I don't get any errors but getopts doesn't assign anything to $opt_f This works just fine on perl 5.8 Windows XP, but it doesn't work on perl 5.12 on Windows 7. There aren't any other versions of perl installed (its...