Query:how to use windows api in my c source code?

J

Jack Dowson

Hello Everybody:
I'm learning c now.I think it's really a tedious job following my
textbook to write programs which are used to deal with math problems.I
want to write some codes related with OS(just like creating processes or
so).Then it may refers to the applying of windows API.
Now here is my question:How to use api in my source code without
error?Will the statement "#include<windows.h>" do(I can't find this head
file in my include directory)?Or there might have some other ways?
By the way:My os is windowXP and compiler is TURBO c2.0.
Any help will be greatly appreciated.

Dowson.
 
W

Walter Roberson

Now here is my question:How to use api in my source code without
error?Will the statement "#include<windows.h>" do

You should ask about this in one of the Windows programing newsgroups.
Sorry, I don't keep track of their names; I usually stick to pure C,
or to C with POSIX extensions. comp.lang.c only discusses the things
defined by the C programming language, not anything OS specific.
 
R

Richard Heathfield

Walter Roberson said:
You should ask about this in one of the Windows programing newsgroups.
Sorry, I don't keep track of their names;

comp.os.ms-windows.programmer.win32
 
J

jacob navia

Jack said:
Hello Everybody:
I'm learning c now.I think it's really a tedious job following my
textbook to write programs which are used to deal with math problems.I
want to write some codes related with OS(just like creating processes or
so).Then it may refers to the applying of windows API.
Now here is my question:How to use api in my source code without
error?Will the statement "#include<windows.h>" do(I can't find this head
file in my include directory)?Or there might have some other ways?
By the way:My os is windowXP and compiler is TURBO c2.0.
Any help will be greatly appreciated.

Dowson.

Normally that will do to use most of the API exposed by windows.
If there are additional header files to be included you should see
that in the documentation of the specific function of the API
you want to use.

Turbo c 2.0 is an outdated compiler. You should use a newer one.

For instance, you can download
http://www.cs.virginia.edu/~lcc-win32
for free

jacob
 
C

CBFalconer

Jack said:
I'm learning c now.I think it's really a tedious job following my
textbook to write programs which are used to deal with math
problems.I want to write some codes related with OS(just like
creating processes or so).Then it may refers to the applying of
windows API. Now here is my question:How to use api in my source
code without error?Will the statement "#include<windows.h>" do(I
can't find this head file in my include directory)?Or there might
have some other ways? By the way:My os is windowXP and compiler
is TURBO c2.0.

Specific system, such as windows, Turbo C, etc. are off-topic here,
where we deal with the C language as defined in the various C
standards. In particular, there is no such include file as
<windows.h> in standard C, so your question is unanswerable here.
Things would be different on a windows news group, but strictly
limited to windows systems.

Try the references in my sig. below:

--
Some useful references about C:
<http://www.ungerhu.com/jxh/clc.welcome.txt>
<http://www.eskimo.com/~scs/C-faq/top.html> (C-faq)
<http://benpfaff.org/writings/clc/off-topic.html>
<http://anubis.dkuug.dk/jtc1/sc22/wg14/www/docs/n869/> (C99 std)
<http://www.dinkumware.com/refxc.html> (C-library}
<http://gcc.gnu.org/onlinedocs/> (GNU docs)
<http://clc-wiki.net/wiki/C_community:comp.lang.c:Introduction>
 
A

Al Balmer

You know better than to answer an off-topic question in this
newsgroup. You should give him a reference to a suitable group.
It wasn't an answer, it was an advertising opportunity.
 
K

Kenny McCormack

I disagree. He does, but he doesn't. :)

In much the same way that most of the American public (and 100% of the
regulars in this NG) "know" that Christ was born of a virgin. "Knowing"
things that you know aren't true is dangerous.
 
N

Net Nanny

Try the references in my sig. below:

If you really intend the OP to see the list of references, put it in the
main body of your post - many people have their newsreaders hide
signatures. Of course, in your case that might well fail and only the
second of your signatures be recognized as a signature.

Either way, this sig/these sigs are in gratuitous violation of basic
netiquette.
 
A

Al Balmer

If you really intend the OP to see the list of references, put it in the
main body of your post - many people have their newsreaders hide
signatures.

I never heard of that. Which newsreaders provide that option? Why
would anyone want to use it?

For the intended purpose, the references are in the proper place. They
do exceed the 4-line limit, of course.
 
M

Morris Dovey

Al Balmer wrote:
| On Thu, 14 Jun 2007 21:42:37 +0200 (CEST), Net Nanny
|
|| On 12 Jun 2007 at 22:56, CBFalconer wrote:
||| Try the references in my sig. below:
||
|| If you really intend the OP to see the list of references, put it
|| in the main body of your post - many people have their newsreaders
|| hide signatures.
|
| I never heard of that. Which newsreaders provide that option? Why
| would anyone want to use it?

It's done all the time, Al - In fact, I just set up a 'rule' on
Outhouse Express that deletes all of netnanny's sigs. :cool:

| For the intended purpose, the references are in the proper place.
| They do exceed the 4-line limit, of course.

BFD! In the context of all other problems in the world today, there
are surely more pressing needs than counting lines in sig files...
 
R

Richard Heathfield

Morris Dovey said:
Al Balmer wrote:
| For the intended purpose, the references are in the proper place.
| They do exceed the 4-line limit, of course.

BFD! In the context of all other problems in the world today, there
are surely more pressing needs than counting lines in sig files...

There are more pressing needs than using an int to receive getchar's
return value, too. But when someone is told that int is appropriate and
yet continues to use char over and /over/ and OVER, what does that tell
us about him?

Chuck has been told over and /over/ and OVER about his sig, and yet he
continues to violate the Usenet convention of four lines. Until he
fixes that, his criticisms of other people's netiquette violations have
little or no moral force.
 
D

Default User

Net Nanny wrote:

You know better than to breach basic netiquette with this over-long
sig. You should cut it down, and omit the second sig.

You are aware that the "second sig" is added by his news service, over
which he has no control, right?




Brian
 
A

Al Balmer

Al Balmer wrote:
| On Thu, 14 Jun 2007 21:42:37 +0200 (CEST), Net Nanny
|
|| On 12 Jun 2007 at 22:56, CBFalconer wrote:
||| Try the references in my sig. below:
||
|| If you really intend the OP to see the list of references, put it
|| in the main body of your post - many people have their newsreaders
|| hide signatures.
|
| I never heard of that. Which newsreaders provide that option? Why
| would anyone want to use it?

It's done all the time, Al - In fact, I just set up a 'rule' on
Outhouse Express that deletes all of netnanny's sigs. :cool:

I can do better - a rule that deletes his entire post :)

I'd be interested in how you get OE to edit a received post with a
rule. In Outlook non-express, it could be done by running a script, I
suppose, but I've never used OE.
 
D

Default User

Al said:
I never heard of that. Which newsreaders provide that option? Why
would anyone want to use it?

I could, after a fashion, by setting the .sig text color to the same as
the background (it's currently a shade of gray somewhat darker than the
background). The text would still be there, and I could drag across it
and see it.
For the intended purpose, the references are in the proper place. They
do exceed the 4-line limit, of course.

True. It's not an flagrant violation, but one all the same.



Brian
 
M

Morris Dovey

Richard Heathfield wrote:
| Morris Dovey said:
|
|| Al Balmer wrote:
| <snip>
||
||| For the intended purpose, the references are in the proper place.
||| They do exceed the 4-line limit, of course.
||
|| BFD! In the context of all other problems in the world today, there
|| are surely more pressing needs than counting lines in sig files...
|
| There are more pressing needs than using an int to receive getchar's
| return value, too. But when someone is told that int is appropriate
| and yet continues to use char over and /over/ and OVER, what does
| that tell us about him?
|
| Chuck has been told over and /over/ and OVER about his sig, and yet
| he continues to violate the Usenet convention of four lines. Until
| he fixes that, his criticisms of other people's netiquette
| violations have little or no moral force.

Agreed. <s>

Still, here in c.l.c it does seem (to me) more appropriate to focus on
C language/usage issues than to waste time beating up on CBF for
teranews' antisocial behavior.

If CBF reads this and likes the idea, I'm willing to host an orphan
page with his C links. That way he can shrink his sig to point to that
page.

BTW, I still have a Post-It with your initials on it stuck to the
front of a small book (ISBN 0-13-110163-3) that you once said you
wanted. If you don't want it, please let me know - else send your
mailing address!
 
R

Richard Heathfield

Morris Dovey said:
Richard Heathfield wrote:

|
| Chuck has been told over and /over/ and OVER about his sig, and yet
| he continues to violate the Usenet convention of four lines. Until
| he fixes that, his criticisms of other people's netiquette
| violations have little or no moral force.

Agreed. <s>

Still, here in c.l.c it does seem (to me) more appropriate to focus on
C language/usage issues than to waste time beating up on CBF for
teranews' antisocial behavior.

Oh, I can live with that. I'm talking about /his/ outsized sig block
data, not his ISP's additions.
BTW, I still have a Post-It with your initials on it stuck to the
front of a small book

Can't be my book, then. :)
 
M

Morris Dovey

Al Balmer wrote:
| On Thu, 14 Jun 2007 16:33:56 -0500, "Morris Dovey"

|| It's done all the time, Al - In fact, I just set up a 'rule' on
|| Outhouse Express that deletes all of netnanny's sigs. :cool:
|
| I can do better - a rule that deletes his entire post :)
|
| I'd be interested in how you get OE to edit a received post with a
| rule. In Outlook non-express, it could be done by running a script,
| I suppose, but I've never used OE.

Well, it's not exactly "editing". If truth be told, it deleted all
headers /and/ the message text right along with the sig. :-D

Never used OE? Excellent decision!
I'm inclined to believe that in its original form OE was a real-time
tectonic emulator with more fault lines than California put together.
 
M

Morris Dovey

Richard Heathfield wrote:
| Morris Dovey said:
|
|| BTW, I still have a Post-It with your initials on it stuck to the
|| front of a small book
|
| Can't be my book, then. :)

Of course not. That would be ISBN 0-672-31896-2, three volumes over.
These days it'd probably be considered an act of terrorism to attempt
sending anything that heavy by air.
 
R

Richard Bos

Default User said:
You are aware that the "second sig" is added by his news service, over
which he has no control, right?

Yes, he does. He can get a real, non-violating news service.

But please don't follow up to Kenny, or to his nyms.

Richard
 

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

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top