Windows graphics problem

M

maan kapoor

hi can u help

i have problems with an example from my textbook on windows console
programming. here is some code to change the background to blue,

asm movb ah, 0x2
asm movb dl, 0x7
asm int 0x21

this works fine on turbo c 2.01.

but i try to compile it with lcc, a free windows compiler, and it doesnt
work.

can u help

thx
 
K

Kaz Kylheku

[...] u [...] i [...] windows [ ... ] console [ ... ] asm [ ... ] lcc

I love it!

IM speak, capitalization, lcc, windows, assembly!

Talk about pounding your fist on the control panel of c.l.c hot buttons.

Let's see how many naives bite!
 
J

jacob navia

maan said:
hi can u help

i have problems with an example from my textbook on windows console
programming. here is some code to change the background to blue,

asm movb ah, 0x2
asm movb dl, 0x7
asm int 0x21

this works fine on turbo c 2.01.

but i try to compile it with lcc, a free windows compiler, and it doesnt
work.

can u help

thx

Your textbook on windows console programming is about
MSDOS console programming. Putting some values in the registers
and calling int 0x21 stopped working more than 12 years ago when MSDOS
died a natural death.

Besides, lcc has another assembler syntax so that your code will not
be understood.


Now, the good news is that lcc has a compatibility library to use the
console, similar to the one turboc uses.

#include <tcconio.h>

int main(bvoid)
{
textbackground(BLUE);
}


You link the above program with tcconio.lib.
 
M

maan kapoor

hi jacob and richard,

thx for ur answers.

actually lcc was only an example because I could get it for free. really i
want a code that will work on ALL compilers inc microsoft and borland.
will ur program do that?

thx
 
J

jacob navia

maan said:
hi jacob and richard,

thx for ur answers.

actually lcc was only an example because I could get it for free. really i
want a code that will work on ALL compilers inc microsoft and borland.
will ur program do that?

thx


No. For that you should buy the source code of tcconio.lib. That will
allow you to compile it under borland and Microsoft.
 
P

Phil Carmody

Kaz Kylheku said:
[...] u [...] i [...] windows [ ... ] console [ ... ] asm [ ... ] lcc

I love it!

IM speak, capitalization, lcc, windows, assembly!

Talk about pounding your fist on the control panel of c.l.c hot buttons.

I think the term is 'bingo', isn't it?
Let's see how many naives bite!

It that missing a 't'?

Phil
 
M

maan kapoor

hi jacob,

where can i download tcconio.lib? and how 2 use it with my code?

thx.
 
C

CBFalconer

maan said:
where can i download tcconio.lib? and how 2 use it with my code?

thx.

You are committing multiple Usenet sins. First, use English. The
abbreviations such as ur, thx, 2 are not understandable to people
who are not facile in English.

Also, please do not top-post. Your answer belongs after (or
intermixed with) the quoted material to which you reply, after
snipping all irrelevant material. See the following links:

<http://www.catb.org/~esr/faqs/smart-questions.html>
<http://www.caliburn.nl/topposting.html>
<http://www.netmeister.org/news/learn2quote.html>
<http://cfaj.freeshell.org/google/> (taming google)
<http://members.fortunecity.com/nnqweb/> (newusers)
 
F

Flash Gordon

maan said:
hi jacob,

where can i download tcconio.lib? and how 2 use it with my code?

Jacob said you should buy it, not that you can just download it. Since
Jacob wrote it he is entirely within his rights to insist on payment for
it. If you wish to buy it then I suggest you email him to make suitable
arrangements.

Also you have said you want it to work with all compilers. Whilst
Jacob's code probably works with the common Windows compilers (and maybe
gcc on Linux as well) I doubt it will work with every compiler for a
hosted implementation (e.g. I would be surprised if it works with IBM's
compilers for AIX). This is NOT a criticism of Jacob, and I am sure that
for suitable payment (which is again a reasonable thing for him to want)
he can make it work for any specific compiler for an implementation
where such things are possible (selecting blue text on a machine with
only a black and white terminal might be problematic).
 
G

Guest

You are committing multiple Usenet sins.  First, use English.  The
abbreviations such as ur, thx, 2 are not understandable to people
who are not facile in English.

"facile in English"?
 
J

jacob navia

maan said:
hi jacob,

where can i download tcconio.lib? and how 2 use it with my code?

thx.
The binary is included with the lcc-win distribution
The source code, to be used with other compilers can be bought
at
www.q-software-solutions.de

Or you can mail me at the address below for prices and delivery.
 
F

Flash Gordon

Richard said:
Flash Gordon <[email protected]> writes:

Did you work that all out on your own? He should contact Jacob who
had already replied to him? You c.l.c logic stands you well...

Believe what you like. I had not seen Jacob's reply and I know that he
does not always read here so there was a chance he would not.

dont think I have ever seen such a poorly done hatchet job in my
professional life. And I have seen a few. Your reply was petty, mean AND
vindictive while only succeeding in making you look like a jealous
little boy who has fallen from Teacher's grace.

It wasn't a hatchet job, so I'm not surprised it did not work as a
hatchet job. Making such a library portable to all compilers is not a
small job. I stated I was not attacking Jacob because sometimes he
misreads comments as attacks when they are not intended as such.
 
C

CBFalconer

Richard said:
.... snip ...

You're wasting your time, Flash. Bright people already know, and
unbright people are not suddenly going to turn bright just because
you state the blindingly obvious, even if you drop to
monosyllables.

Just like your earlier comment, quoted below:

|| You are committing multiple Usenet sins.
|
| I can accept and even agree that they are breaches of convention
-
| but sin? Which god is he disobeying by using "2" instead of "to"?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,773
Messages
2,569,594
Members
45,119
Latest member
IrmaNorcro
Top