Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: msdos programming  (Read 13520 times)

0 Members and 1 Guest are viewing this topic.

tommmy

  • Guest
msdos programming
« on: March 15, 2005, 09:33:13 AM »
hey,
I need some help with programming in ms-dos,
wich command is used to calculate stuf   ???
thanx, Tom

gussery

  • Guest
Re: msdos programming
« Reply #1 on: March 15, 2005, 12:19:29 PM »
MS-DOS is an operating system, not a programming language.  Technically, you cannot program in MS-DOS.

Can you be more specific about what you are trying to do?

tommmy

  • Guest
Re: msdos programming
« Reply #2 on: March 16, 2005, 09:18:03 AM »
I know I know, but you can whrite command lines in word and save it as a .bat file, so the commands are executed by dos. my question was wich command is used to calculate stuf ( e.g. 3+2 ), so i can make formula's and echo the result
thanx in advance
tom

gussery

  • Guest
Re: msdos programming
« Reply #3 on: March 16, 2005, 11:14:17 AM »
There are none that I am aware of without calling another program.  Remember DOS is a Disk Operating System so most of the commands available in DOS, thus batch files, have to do with disk and file operations.

Sidewinder



    Guru

    Thanked: 139
  • Experience: Familiar
  • OS: Windows 10
Re: msdos programming
« Reply #4 on: March 16, 2005, 12:50:41 PM »
Batch files were never intended to do what you are requesting. In general they just run a series of commands that you could just as easily have typed at the command prompt. Branching and decision making in a batch file is fairly primitive.

One good language for DOS is REXX. REXX runs on everything from mainframes, DOS, Windows, and Linux. The best part is that it's free.

REXX is easy to learn, can read records from a file, manipulate the data and produce formatted output. You can run DOS commands and other programs from within REXX. REXX also has specialized function libraries (download separately) for database access, system functions, high-level math, and communications.

You can download REXX from:

http://kilowattsoftware.com/r4page.htm

If you need any REXX libraries try this site:

http://www.borg.com/~jglatt/rexx/win32/rxusrw32.htm

Good luck.

8)
« Last Edit: March 16, 2005, 12:53:20 PM by Sidewinder »
The true sign of intelligence is not knowledge but imagination.

-- Albert Einstein

johnwill

  • Guest
Re: msdos programming
« Reply #5 on: March 19, 2005, 03:21:12 PM »
There are various DOS batch extender applications, including some that do calculations.  You might check the batch utilities here: http://garbo.uwasa.fi/pc/

martinweston

  • Guest
Re: msdos programming
« Reply #6 on: March 21, 2005, 05:53:19 AM »
Could use Q basic. Found on older windows cd's, can be run thru dos.

Marty

ludo

  • Guest
Re: msdos programming
« Reply #7 on: April 01, 2005, 02:48:13 PM »
hello,
save this under c:\test.bat
@echo off
set /A result=%1%2%3%4%5%6%7%8%9
echo resultat : %result%

then type test 5+2*9 at command prompt of c:\
and get the result
:P

ludo

  • Guest
Re: msdos programming
« Reply #8 on: April 01, 2005, 02:58:35 PM »
sorry just need to use :
@echo off
set /A result=%1
echo resultat : %result%

ocean

  • Guest
Re: msdos programming
« Reply #9 on: April 05, 2005, 10:20:20 AM »
HeY ..

I tried to install REXX .. but it doesnt work with me! :-/

anYone can helP Plz??

thanks

Sidewinder



    Guru

    Thanked: 139
  • Experience: Familiar
  • OS: Windows 10
Re: msdos programming
« Reply #10 on: April 05, 2005, 07:10:06 PM »
Ocean,

Sorry the REXX didn't work out. It's really a good language but I failed to realize the complications of setting it up from a zip file. Also there were variations from Classic Rexx.

Maybe you should try QBasic. You can download here for free:

http://www.geocities.com/TimesSquare/Arena/5451/qbasic/downloads/

If you get QBasic, you should be able to find any tutorials and documentation on the net.

Good luck.

8)
The true sign of intelligence is not knowledge but imagination.

-- Albert Einstein

ocean

  • Guest
Re: msdos programming
« Reply #11 on: April 05, 2005, 10:48:26 PM »
Thanks Sidewinder  :)

I'll trY it when comin back from universitY ..but

can't i find a Rexx not in a ziP file ? am reallY interested in  ::)
« Last Edit: April 05, 2005, 10:50:59 PM by ocean »

Ludo

  • Guest
Re: msdos programming
« Reply #12 on: April 06, 2005, 07:43:59 AM »
Hello,
I remember i found a rexx/windows software on the net, few years ago, i can't remember the link but the name was Winrexx.

Sidewinder



    Guru

    Thanked: 139
  • Experience: Familiar
  • OS: Windows 10
Re: msdos programming
« Reply #13 on: April 06, 2005, 08:08:16 AM »
Ocean,

I was able to find Object Rexx at:

http://sourceforge.net/project/showfiles.php?group_id=119701

Download the file name ooRexx300.exe. It will run on Windows (32 bit) and contains both Classic Rexx and Object Rexx. The documentation download file is oorexx-docs-3.0.0.zip on the same page. Complete details of the product are at: http://www.oorexx.org/

If you need to run this on a DOS machine, you can download Classic Rexx from:

http://sourceforge.net/project/showfiles.php?group_id=28102

Download the file name regina33.exe. The Documentation file is regina33.pdf on the same page. Complete details can be found at http://regina-rexx.sourceforge.net/index.html

Personally I would download the Object Rexx version. You can still write simple Rexx programs with the option to venture into the world of objects. The best part is both versions are free.

Good luck.

8)
The true sign of intelligence is not knowledge but imagination.

-- Albert Einstein

ocean

  • Guest
Re: msdos programming
« Reply #14 on: April 07, 2005, 08:38:08 AM »
Thank You Sidewinder  8)

I'll read the documentation .. and trY to be Good at it ..