473,387 Members | 1,540 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

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

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.
Jun 12 '07
69 2978
Chris Hills said:
In article <46***************@yahoo.com>, CBFalconer
<cb********@yahoo.comwrites
<snip>
>>You know better than to answer an off-topic question in this
newsgroup. You should give him a reference to a suitable group.

He can answer who he likes, how he likes.
So can Chuck.
Don't start the OT rubbish again.
Don't forget - he can answer who he likes, how he likes.

--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
Jun 18 '07 #51
Chris Hills said:
In article <ln************@nuthaus.mib.org>, Keith Thompson
<ks***@mib.orgwrites
>>Chris Hills <ch***@phaedsys.orgwrites:
<snip>
>>Don't start the OT rubbish again. Your definition is yours. Others
have other definitions of OT. (that is On topic or Off Topic as
suites)

And you've never told us *your* definition of what's topical and what
isn't.

We largely the same as yours but I would widen it to most C questions.
That would be *narrowing* it. All C questions are topical here. The OP,
however, was asking a Windows API question, not a C question.
However as you point out in depth discussions of various OS and other
things is not the main aim of this NG.
Right. So what's your beef?
However I would not react to posters for being OT in the way you do,
He can answer who he likes, how he likes, as you said yourself.
Be nicer, more helpful.
I agree that that's good advice, but none of us can mandate it.
Relax if you answer more of, what you call, OT questions on here we
would not get endless arguments of what is OT and what is OT
Instead, we'd get a torrent of people asking OT questions and expecting
answers, and the real C discussions would get lost, and at least some
of the real C experts would decide that the group is no longer a good
use of their time, and we'd end up in the same place as clc++ a few
years ago.
Your fear of this ng not staying racially pure has overtones of AH
not KR
Godwin's Law. This thread is now over, and you lose.

--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
Jun 18 '07 #52
Chris Hills <ch***@phaedsys.orgwrites:
In article <ln************@nuthaus.mib.org>, Keith Thompson
<ks***@mib.orgwrites
[...]
>>And you've never told us *your* definition of what's topical and what
isn't.

We largely the same as yours but I would widen it to most C
questions. However as you point out in depth discussions of various OS
and other things is not the main aim of this NG.
I don't know what you mean by "most C questions". Questions that are
actually about the C programming language are topical. (The language
is defined by the standard(s).)

So you agree that questions about operating systems are off-topic, but
you object to anyone complaining about them?
However I would not react to posters for being OT in the way you do,
Be nicer, more helpful. Some of the net nannies on here seem to have
personal problems.
I give the best help I can, by telling off-topic posters that they
should ask in a forum where their questions are topical. Attempting
to answer off-topic questions here is far less helpful. We've been
over this.
Relax if you answer more of, what you call, OT questions on here we
would not get endless arguments of what is OT and what is OT
No, if we answer more OT questions here, the newsgroup will collapse,
just as comp.lang.c++ nearly did a few years ago. Again, we've been
over this.
Your fear of this ng not staying racially pure has overtones of AH
not KR
"Racially pure"? What kind of nonsense is that? (I don't know what
you mean by AH and KR, but that's all right.)

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Jun 18 '07 #53
Chris Hills wrote:
Your fear of this ng not staying racially pure has overtones of AH not
KR
What have Avalon Hill to do with this? And you've got Reiner Knizia's
initials wackbards.

--
Chris "games are off-topic here, yes?" Dollin

Hewlett-Packard Limited Cain Road, Bracknell, registered no:
registered office: Berks RG12 1HN 690597 England

Jun 18 '07 #54
Chris Hills wrote:
>
We largely the same as yours but I would widen it to most C questions.
However as you point out in depth discussions of various OS and other
things is not the main aim of this NG.

However I would not react to posters for being OT in the way you do, Be
nicer, more helpful. Some of the net nannies on here seem to have
personal problems.

Relax if you answer more of, what you call, OT questions on here we
would not get endless arguments of what is OT and what is OT

Your fear of this ng not staying racially pure has overtones of AH not KR
The same people that say "off topic" to every windows related questions
will answer any question about gcc, for instance the huge thread about
how to elicit a specific warning with gcc.
Subject: "How to get warnings about implicit narrowing in c99 code"
Message ID: <f4***********@energise.enta.net>

And that is one of many. They will discuss anything, from specific mail
software to specific compiler implementations.

It is only when you do not share their Linux+Unix are good, windows is
evil standpoint that they will start telling their "off topic" nonsense.

They speak about the danger for this group being too specific to some
implementation but they reduce this newsgroup to just discussions about
homework, or the eternal questions about

I did i++ = i++ and it doesn't work.

jacob
Jun 18 '07 #55
jacob navia wrote:
Chris Hills wrote:
>>
We largely the same as yours but I would widen it to most C questions.
However as you point out in depth discussions of various OS and other
things is not the main aim of this NG.

However I would not react to posters for being OT in the way you do,
Be nicer, more helpful. Some of the net nannies on here seem to have
personal problems.

Relax if you answer more of, what you call, OT questions on here we
would not get endless arguments of what is OT and what is OT

Your fear of this ng not staying racially pure has overtones of AH
not KR

The same people that say "off topic" to every windows related questions
will answer any question about gcc, for instance the huge thread about
how to elicit a specific warning with gcc.
gcc runs on windows....

--
Ian Collins.
Jun 18 '07 #56
In article <46***********************@news.orange.fr>, jacob navia
<ja***@jacob.remcomp.frwrites
>Chris Hills wrote:
> We largely the same as yours but I would widen it to most C
questions. However as you point out in depth discussions of various
OS and other things is not the main aim of this NG.
However I would not react to posters for being OT in the way you do,
Be nicer, more helpful. Some of the net nannies on here seem to
have personal problems.
Relax if you answer more of, what you call, OT questions on here we
would not get endless arguments of what is OT and what is OT
Your fear of this ng not staying racially pure has overtones of AH
not KR

The same people that say "off topic" to every windows related questions
will answer any question about gcc, for instance the huge thread about
how to elicit a specific warning with gcc.
I noticed that GCC is definitely OT here as it has it's own standard.
>Subject: "How to get warnings about implicit narrowing in c99 code"
Message ID: <f4***********@energise.enta.net>

And that is one of many. They will discuss anything, from specific mail
software to specific compiler implementations.

It is only when you do not share their Linux+Unix are good, windows is
evil standpoint that they will start telling their "off topic" nonsense.
I have noticed that too

--
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills Staffs England /\/\/\/\/
/\/\/ ch***@phaedsys.org www.phaedsys.org \/\/\
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/

Jun 18 '07 #57
Chris Hills said:
In article <46***********************@news.orange.fr>, jacob navia
<ja***@jacob.remcomp.frwrites
>>
It is only when you do not share their Linux+Unix are good, windows is
evil standpoint that they will start telling their "off topic"
nonsense.

I have noticed that too
I haven't, particularly. What I *have* noticed is that Mr Navia's
articles demonstrate a marked tendency to get hold of the wrong end of
the stick.

If people here are discussing Linux or Unix, they're off-topic, and no
doubt someone will say so. But very few such discussions actually
occur, as far as I can tell, certainly when compared with the number of
times Mr Navia treats this group as a marketing tool for his
implementation.

--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
Jun 18 '07 #58
In article <aM******************************@bt.com>, Richard Heathfield
<rj*@see.sig.invalidwrites
>Chris Hills said:
>In article <46***********************@news.orange.fr>, jacob navia
<ja***@jacob.remcomp.frwrites
>>>
It is only when you do not share their Linux+Unix are good, windows is
evil standpoint that they will start telling their "off topic"
nonsense.

I have noticed that too

I haven't, particularly. What I *have* noticed is that Mr Navia's
articles demonstrate a marked tendency to get hold of the wrong end of
the stick.
I assume English is not his mother tongue.
>If people here are discussing Linux or Unix, they're off-topic, and no
doubt someone will say so. But very few such discussions actually
occur, as far as I can tell, certainly when compared with the number of
times Mr Navia treats this group as a marketing tool for his
implementation.
To be fair it is no more than any FOSS devotee pushes their favourite
brand of Linux or Gcc. Some people have it in their sigs.

You only have to ask what is the best compiler for windows and you get a
stream of people listing their favourite Gcc, Cygwin compiler (and
getting very annoyed when some one points out the best bet for a novice
is probably the Free MS VC express thingy)

Then it is followed by the usual voices suggesting the OP dumps it al
for Linux and Gcc...

I assume as someone who is pushing a.n.other free compiler he is as
sensitive to the competition as the GCC crowd are when I suggest the
Free MS compiler for Windows.
BTW I still stand by that. For a complete novice to have a compiler for
windows written by the people who did the OS and with all the
intergration, examples and onboard help it is the easiest start. It may
not be "The Best" but it will get him up and running to the point where
he knows what he wants to do and can make a better assessment of the
other free tools out there.

Some people want to just install and program not have to knit their own
system.

--
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills Staffs England /\/\/\/\/
/\/\/ ch***@phaedsys.org www.phaedsys.org \/\/\
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/

Jun 18 '07 #59
Chris Hills said:
In article <aM******************************@bt.com>, Richard
Heathfield <rj*@see.sig.invalidwrites
>>Chris Hills said:
>>In article <46***********************@news.orange.fr>, jacob navia
<ja***@jacob.remcomp.frwrites

It is only when you do not share their Linux+Unix are good, windows
is evil standpoint that they will start telling their "off topic"
nonsense.

I have noticed that too

I haven't, particularly. What I *have* noticed is that Mr Navia's
articles demonstrate a marked tendency to get hold of the wrong end of
the stick.

I assume English is not his mother tongue.
I accept that, but he is so quick to give and take offence that I don't
think it's just a language issue.
>>If people here are discussing Linux or Unix, they're off-topic, and no
doubt someone will say so. But very few such discussions actually
occur, as far as I can tell, certainly when compared with the number
of times Mr Navia treats this group as a marketing tool for his
implementation.

To be fair it is no more than any FOSS devotee pushes their favourite
brand of Linux or Gcc.
Yes, it is. Far more.

Some people have it in their sigs.
Sigs are a different kettle of fish altogether. If Mr Navia wants a
four-line lcc ad in every single article he posts, the sig is the place
to put it. The content of sigs does not have to be topical and, AFAIK,
is allowed to be commercial.
You only have to ask what is the best compiler for windows and you get
a stream of people listing their favourite Gcc, Cygwin compiler (and
getting very annoyed when some one points out the best bet for a
novice is probably the Free MS VC express thingy)
The very, very best thing for a novice is to learn that the question
"which is the best" has no meaning until his meaning of "best" is
nailed down. Once that's done, the question is properly referred to
comp.os.ms-windows.programmer.win32 where the expertise exists to
answer the question properly.
Then it is followed by the usual voices suggesting the OP dumps it al
for Linux and Gcc...
Such suggestions would be more topical in a Linux or gcc newsgroup.

<snip>

--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
Jun 18 '07 #60
Keith Thompson <ks***@mib.orgwrites:
Chris Hills <ch***@phaedsys.orgwrites:
[...]
>Your fear of this ng not staying racially pure has overtones of AH
not KR

"Racially pure"? What kind of nonsense is that? (I don't know what
you mean by AH and KR, but that's all right.)
My guess is that "KR" refers to Kernighan & Ritchie. Does AH refer to
Adolf Hitler? (That hadn't occurred to me until I saw Richard H's
followup.) Have you decided to give up on civility and become a
troll?

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Jun 18 '07 #61
Richard Heathfield wrote:
Chris Hills said:
><cb********@yahoo.comwrites

<snip>
>>You know better than to answer an off-topic question in this
newsgroup. You should give him a reference to a suitable group.

He can answer who he likes, how he likes.

So can Chuck.
>Don't start the OT rubbish again.

Don't forget - he can answer who he likes, how he likes.
I THINK I made a fairly mild topical complaint, which has expanded
into something like 60 messages beating firmly on one another.

--
<http://www.cs.auckland.ac.nz/~pgut001/pubs/vista_cost.txt>
<http://www.securityfocus.com/columnists/423>
<http://www.aaxnet.com/editor/edit043.html>
cbfalconer at maineline dot net

--
Posted via a free Usenet account from http://www.teranews.com

Jun 19 '07 #62
Richard Heathfield wrote:
Chris Hills said:
><ja***@jacob.remcomp.frwrites
>>>
It is only when you do not share their Linux+Unix are good,
windows is evil standpoint that they will start telling their
"off topic" nonsense.

I have noticed that too
.... snip ...
>
If people here are discussing Linux or Unix, they're off-topic,
and no doubt someone will say so. But very few such discussions
actually occur, as far as I can tell, certainly when compared
with the number of times Mr Navia treats this group as a
marketing tool for his implementation.
As a one line refutation to Chris, gcc is advancing (slowly) to C99
conformance, while Microsoft is ignoring that advance.

--
<http://www.cs.auckland.ac.nz/~pgut001/pubs/vista_cost.txt>
<http://www.securityfocus.com/columnists/423>
<http://www.aaxnet.com/editor/edit043.html>
cbfalconer at maineline dot net

--
Posted via a free Usenet account from http://www.teranews.com

Jun 19 '07 #63
CBFalconer said:
<http://www.cs.auckland.ac.nz/~pgut001/pubs/vista_cost.txt>
<http://www.securityfocus.com/columnists/423>
<http://www.aaxnet.com/editor/edit043.html>
cbfalconer at maineline dot net
*** APPLAUSE!!! ***

--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
Jun 19 '07 #64
In article <46***************@yahoo.com>, CBFalconer
<cb********@yahoo.comwrites
>Richard Heathfield wrote:
>Chris Hills said:
>><ja***@jacob.remcomp.frwrites

It is only when you do not share their Linux+Unix are good,
windows is evil standpoint that they will start telling their
"off topic" nonsense.

I have noticed that too
... snip ...
>>
If people here are discussing Linux or Unix, they're off-topic,
and no doubt someone will say so. But very few such discussions
actually occur, as far as I can tell, certainly when compared
with the number of times Mr Navia treats this group as a
marketing tool for his implementation.

As a one line refutation to Chris, gcc is advancing (slowly) to C99
conformance, while Microsoft is ignoring that advance.
I am told that MS is very standards compliant these days.

BTW do MS do a C compiler? I thought it was C++

--
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills Staffs England /\/\/\/\/
/\/\/ ch***@phaedsys.org www.phaedsys.org \/\/\
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/

Jun 19 '07 #65
Chris Hills said:
In article <46***************@yahoo.com>, CBFalconer
<cb********@yahoo.comwrites
<snip>
>>As a one line refutation to Chris, gcc is advancing (slowly) to C99
conformance, while Microsoft is ignoring that advance.

I am told that MS is very standards compliant these days.
They conform to the current de facto C Standard, C90, yes. They have
ignored C99, but so has everyone else, so that's okay.
BTW do MS do a C compiler?
Yes.
I thought it was C++
No, their C compiler is definitely a C compiler, not a C++ compiler.

--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
Jun 19 '07 #66
In article <Zp******************************@bt.com>, Richard Heathfield
<rj*@see.sig.invalidwrites
>Chris Hills said:
>In article <46***************@yahoo.com>, CBFalconer
<cb********@yahoo.comwrites

<snip>
>>>As a one line refutation to Chris, gcc is advancing (slowly) to C99
conformance, while Microsoft is ignoring that advance.

I am told that MS is very standards compliant these days.

They conform to the current de facto C Standard, C90, yes. They have
ignored C99, but so has everyone else, so that's okay.
I think PJ Plauger said MS are very C99 compliant
I must dig out the email he said it in..

--
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills Staffs England /\/\/\/\/
/\/\/ ch***@phaedsys.org www.phaedsys.org \/\/\
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/

Jun 19 '07 #67
Chris Hills said:
Richard Heathfield writes
>>Chris Hills said:
<snip>
>>I am told that MS is very standards compliant these days.

They conform to the current de facto C Standard, C90, yes. They have
ignored C99, but so has everyone else, so that's okay.

I think PJ Plauger said MS are very C99 compliant
If so, and if he means that they have a conforming implementation (both
compiler and library), then that's very welcome news, but presumably
quite a late change. I must confess I have no Microsoft software dated
after 2005 (other than an occasional XP update, I guess), so it is
certainly possible that I am a little behind the curve.

--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
Jun 19 '07 #68
In article <op*********************@bt.com>, Richard Heathfield
<rj*@see.sig.invalidwrites
>Chris Hills said:
>Richard Heathfield writes
>>>Chris Hills said:
<snip>
>>>I am told that MS is very standards compliant these days.

They conform to the current de facto C Standard, C90, yes. They have
ignored C99, but so has everyone else, so that's okay.

I think PJ Plauger said MS are very C99 compliant

If so, and if he means that they have a conforming implementation (both
compiler and library), then that's very welcome news, but presumably
quite a late change. I must confess I have no Microsoft software dated
after 2005 (other than an occasional XP update, I guess), so it is
certainly possible that I am a little behind the curve.
I must admit I was surprised at the comment but he should know. It was
in an email posted to an NG where he named several compilers GCC, MS and
another and said how compliant they are to C89, 90, 99.

I have had a quick look for it but no lock.

I found the item I was looking for on languages and suitability for
safety critical It was in the IEE Computing and Control Journal Feb
2000 so it will only have covered C as C90/95

--
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills Staffs England /\/\/\/\/
/\/\/ ch***@phaedsys.org www.phaedsys.org \/\/\
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/

Jun 19 '07 #69
In article <nW**************@phaedsys.demon.co.uk>,
Chris Hills <ch***@phaedsys.demon.co.ukwrote:
....
>However I would not react to posters for being OT in the way you do, Be
nicer, more helpful. Some of the net nannies on here seem to have
personal problems.
Gee, ya think? The regs here are the very definition of case studies
in, as you charitably put it, personal problems.
Jun 25 '07 #70

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Yannick Turgeon | last post by:
Hello all, I tryed to simplify the problem as much as possible. I'll start with the DDL: ---------------------------------- CREATE TABLE #MyTable( NoID INT, Type CHAR,...
0
by: Brandon Potter | last post by:
Is there a way for .NET to query a Windows Media Services Publishing Point to find out if it's currently broadcasting? Thanks! Brandon
6
by: Nicolae Fieraru | last post by:
Hi All, I have a query, Select Count(BoolField) from tblMyTable, Where BoolField = true. If I run the query by itself, it returns the number of true records I want to use the result of that...
2
by: modfreq | last post by:
Hi, I am fairly new to Access and VBA. I have found a few threads relating to my problem, but none have led to a solution, so if I hope that I am not restating an old question... I am writing...
0
by: Aruna Tennakoon | last post by:
Hi Every one, I need to a small sample code done using ASP.NET to query Windows Media Server connections ? thanks, -Aruna
1
by: PaulW99 | last post by:
I'm an experienced mainframe programmer, but new to programming in Access. I have an application written in VBA that attempts to export the results of a query to an Excel spreadsheet using code like...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.