dos

Load a new exe with gdb

I am currently trying to make use of gdb to disassemble an exe, and from my home, I start the application like such: gdb "c:\file.exe" And gdb starts and loads that file automatically. Now the problem is that from where I am atm, the command prompt is disabled and thus I cannot run the terminal window with the filename as the argumen...

Replacement for Vern Buerg's list.com in 64 bit Windows 7

I would like to find a replacement for list.com, specifically the ability to accept piped input. For example: p4 sync -n | list which accepts the output of the perforce command and displays the results in the viewer/editor for manipulation or saving. I know that I would send the output to a file and then open the file in the viewer/ed...

Batch File to Delete Folders

I found some code to delete folders, in this case deleting all but 'n' # of folders. I created 10 test folders, plus 1 that was already there. I want to delete all but 4. The code works, it leaves 4 of my test folders, except that it also leaves the other folder. Is there some attribute of the other folder that's getting checked in the b...

How can I make an "are you sure" prompt in a DOS batchfile?

I have a batch file that automates copying a bunch of files from one place to the other and back for me. Only thing is as much as it helps me I keep accidentally selecting that command off my command buffer and mass overwriting uncommited changes. What code would I need for my .bat file to make it say "are you sure", and make me type "...

How to enable DOS in Vista or Win7

AFAIK there is no DOS in vista and windows 7, but I need to execute system program written on assembler to read and write data (BIOS). I can't do thus from Vista, because I'm in user more (ring-3). That's why I have 2 ideas: - execute form DOS (but I need DOS); - write service that executes before I log in to user mode. Loading DOS f...

Printing to a Local Shared Printer When the Network is down

I have some legacy application logic that sends files to an attached printer using a DOS copy command: copy fileToPrint \myLocalComputerName\printerShareName The problem is that even though the application is running on the computer that's physically attached to the printer since it's using a network "share" it requires the network be ...

Compilers for DOS32?

Where can I get BASIC and C/C++ Compilers for MS-DOS? ...

When executing batch file from Java Runtime, native DOS commands fail to run

When I execute the batch file directly in DOS, everything runs as expected. But when I execute the batch file from Java runTime, it will run only the commands that invoke jar files (ie. invoke the JVM). It does not run any native dos commands. One problem is that I have no console to know why this is happening. I'm wondering if it's...

snag colored text command window output

I sometimes run command line code that produces output in colored letters. I would like to somehow find a way to copy that out put and either port it in RTF format or HTML. I did something simular to this once with a windows app that output text in rtf format. I copied it to a windows write program and safted it as rtf and then use a c...

Need to refresh a single ie7 web tab from command line...

Hi, I need to create a batch file that will stop a process and then refresh a defined tab in internet explorer 7. Just need some help/pointers on the tab refresh part or if it's even possible... I don't want IE to open another tab, and another browser is not an option as the web based program is only compatible with IE. Any ideas? I've...

User Input - DOS batch file

I get a bat file as below: @ECHO Executing scripts... PAUSE for %%X in (*.SQL) do SQLCMD -S localhost -d CTL -I -i "%%X" >> ResultScript.txt pause In this I want to has user inputs for localhost (Sql server instance) and CTL (database). How can this be achieved in DOS (os: WinXP) Thanks ...

DOS/sqlplus "Handle is invalid" error?

I have the following batch script: sqlplus ms/ms@orcl < drop.sql sqlplus ms/ms@orcl < create.1.0.sql This works fine when I double click on the bat file in Windows Explorer and run it. But when I type the command name from the DOS prompt I get an error: C:\>create.bat C:\>sqlplus ms/ms@orcl 0<drop.sql The handle is invalid. C:\...

DOS echo command can't echo a user-set variable

What did I do to screw up my CMD shell? Windows XP Pro, open a cmd window and do: C:\>set tt = name C:\>set tt tt = name C:\>echo %tt% %tt% C:\>echo %time% 14:13:28.67 The echo command doesn't work for some reason. I can echo the built-in variables just fine. Tried it on another computer and that works as expected ...

recurse directory for file extension with total?

I want to know how much disk space is being used by zip files (or any other extension) in a particular directory tree. Is this possible on the command line (in a batch program)? I can list them, ie: dir /s *.zip or using "forfiles": forfiles /p d:\wincap /s /m *.zip /c "cmd /c echo @fsize" I need it in a batch program, because I wan...

If Service Exists Condition

How would you check if a WIN32 service exists and, if so, do some operation? ...

How to get cleartool diff to return to command line while diff viewer is still open?

As described in one of the answers to SO question "Any way to use a custom diff tool with cleartool/clearcase?" I have installed WinMerge and a single diff opens fine in WinMerge based on a command of the form cleartool diff -g filename filename@@clearcase-virtual-path-to-version-I-want-to_compare-to But when I run that command in cygw...

How do you print a smiley-face in assembly?

I wrote a program in assembler and compiled it. It is meant to print a blue smiley face and then wait for the user to press a key before it terminates. It does do that last bit but it doesn't print the smiley face. Can someone explain what have I done wrong ? CSEG segment org 100h Begin: mov ax,0B800h mov es,ax mov di,0 mov ah,31 mov ...

Getting output on the same line of a file in DOS?

If I have output from two sources that I want to put together on the same line, how would I do that? In my case I have a file and a program. The file is something like this: listOfThings= My program outputs a list of strings on a single line. I want have a small script that runs nightly to put these two things together on a single li...

How do I redirect output into Gvim as a list of files to be opened?

I would like findstr /m background *.vim | gvim to open all *.vim files containing background in a single instance of gvim - but I can't get the piping to work. This is very similar to this question but instead of capturing the stdin output I would like GViM to treat the output as a list of files to be opened - and on a dos system so x...

grabbing a subtring in a batch file

I am trying to automate DNS zone creation by using a batch file fired through one of Plesk's events. Using the dnscmd command, the batch checks to see if the zone exists. If the zone does not exist, the script adds it according to specs. If it does exist, and it is a secondary zone, the script deletes and recreates it according to s...