Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Cannot open include file: 'iphlpapi.h':

1,686 views
Skip to first unread message

Vikas Kumar

unread,
Jul 31, 2006, 7:31:13 AM7/31/06
to
A pre made project(in MFC) is given to me
When I tried to build that project it is giving following error
Cannot open include file: 'iphlpapi.h': No such file or directory

Please help

Ajay Kalra

unread,
Jul 31, 2006, 9:33:58 AM7/31/06
to
> A pre made project(in MFC) is given to me
> When I tried to build that project it is giving following error
> Cannot open include file: 'iphlpapi.h': No such file or directory
>


I believe this is part of Platform SDK. You will need to install the
SDK. On my machine I can see this file in PlatformSDK\Include
directory. I can also this under SmartDevices\SDK... directory.

---
Ajay

Vikas Kumar

unread,
Aug 1, 2006, 1:57:32 AM8/1/06
to
I am having this file
C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\Include
here
but it is not in my visual studio 6 its in .net
so do i have to install something or do up some settings
"Ajay Kalra" <ajay...@yahoo.com> wrote in message
news:1154352838.0...@s13g2000cwa.googlegroups.com...

Vikas Kumar

unread,
Aug 1, 2006, 5:33:14 AM8/1/06
to
I installed Microsoft SDK
it get installed on following path with file in include
C:\Program Files\Microsoft SDK\include
but still it is giving the same error
fatal error C1083: Cannot open include file: 'iphlpapi.h': No such file or
directory

"Ajay Kalra" <ajay...@yahoo.com> wrote in message
news:1154352838.0...@s13g2000cwa.googlegroups.com...

Joseph M. Newcomer

unread,
Aug 1, 2006, 8:21:49 AM8/1/06
to
Did you search for this file on your machine? Did you find it? If you found it, is the
directory in your include search path?
joe

Joseph M. Newcomer [MVP]
email: newc...@flounder.com
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm

Vikas Kumar

unread,
Aug 1, 2006, 9:03:51 AM8/1/06
to
yes its here
C:\Program Files\Microsoft SDK\include\iphlpapi.h

my project is in different directory
now what settings and from where to do
I don't have idea i am new to this environment
"Joseph M. Newcomer" <newc...@flounder.com> wrote in message
news:6qhuc2du92gcilcbu...@4ax.com...

Ajay Kalra

unread,
Aug 1, 2006, 9:30:21 AM8/1/06
to

Vikas Kumar wrote:
> yes its here
> C:\Program Files\Microsoft SDK\include\iphlpapi.h
>
> my project is in different directory
> now what settings and from where to do
> I don't have idea i am new to this environment

In VC6, you can include this directory in directory tab under
Tools::Options dialog. You will need to include the library files as
well on the same tab.

---
Ajay

David Ching

unread,
Aug 1, 2006, 12:30:33 PM8/1/06
to

"Vikas Kumar" <efe...@newsgroups.nospam> wrote in message
news:OJsC77S...@TK2MSFTNGP03.phx.gbl...

>I am having this file
> C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\Include
> here
> but it is not in my visual studio 6 its in .net

In VC6, select Tools | Options. Click on the Directories tab, and add

"C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\PlatformSDK\Include"

to the Include list. Also add "C:\Program Files\Microsoft Visual Studio
.NET 2003\Vc7\PlatformSDK\Lib" to the Library list.

-- David


Joseph M. Newcomer

unread,
Aug 1, 2006, 12:50:40 PM8/1/06
to
Then you need to make sure this directory is included in the search path for your build.
You can do this by setting the global state of search directories, or you can just add it
as an include directory in your project.
joe

Vikas Kumar

unread,
Aug 2, 2006, 3:02:24 AM8/2/06
to
when i include the folder
it gives the following errors
c:\program files\microsoft sdk\include\iphlpapi.h(183) : error C2065:
'PMIB_ICMP_EX' : undeclared identifier
c:\program files\microsoft sdk\include\iphlpapi.h(183) : error C2146: syntax
error : missing ')' before identifier 'pStats'
c:\program files\microsoft sdk\include\iphlpapi.h(183) : warning C4229:
anachronism used : modifiers on data are ignored
c:\program files\microsoft sdk\include\iphlpapi.h(185) : error C2059: syntax
error : ')'
"David Ching" <d...@remove-this.dcsoft.com> wrote in message
news:JkLzg.3395$uo6...@newssvr13.news.prodigy.com...

Vikas Kumar

unread,
Aug 2, 2006, 3:03:01 AM8/2/06
to
when i include the directory path

it gives the following errors
c:\program files\microsoft sdk\include\iphlpapi.h(183) : error C2065:
'PMIB_ICMP_EX' : undeclared identifier
c:\program files\microsoft sdk\include\iphlpapi.h(183) : error C2146: syntax
error : missing ')' before identifier 'pStats'
c:\program files\microsoft sdk\include\iphlpapi.h(183) : warning C4229:
anachronism used : modifiers on data are ignored
c:\program files\microsoft sdk\include\iphlpapi.h(185) : error C2059: syntax
error : ')'
"Joseph M. Newcomer" <newc...@flounder.com> wrote in message
news:rh1vc21n6lefb3vl6...@4ax.com...

David Ching

unread,
Aug 2, 2006, 10:19:28 AM8/2/06
to

"Vikas Kumar" <efe...@newsgroups.nospam> wrote in message
news:OEP6yEgt...@TK2MSFTNGP05.phx.gbl...

> when i include the folder
> it gives the following errors
> c:\program files\microsoft sdk\include\iphlpapi.h(183) : error C2065:
> 'PMIB_ICMP_EX' : undeclared identifier
> c:\program files\microsoft sdk\include\iphlpapi.h(183) : error C2146:
> syntax error : missing ')' before identifier 'pStats'
> c:\program files\microsoft sdk\include\iphlpapi.h(183) : warning C4229:
> anachronism used : modifiers on data are ignored
> c:\program files\microsoft sdk\include\iphlpapi.h(185) : error C2059:
> syntax error : ')'

Make sure you include the platform sdk folder ON TOP OF the one that comes
with Visual Studio in the folder list. So that if there are the same files
in the two folders, the top one (the newest one) will be used.

-- David


Vikas Kumar

unread,
Aug 3, 2006, 2:45:40 AM8/3/06
to
thanks I already do this and it works

"David Ching" <d...@remove-this.dcsoft.com> wrote in message
news:Qv2Ag.1697$9T3....@newssvr25.news.prodigy.net...

Joseph M. Newcomer

unread,
Aug 7, 2006, 12:54:18 AM8/7/06
to
Which version of the Platform SDK do you have? I'll see if I can figure out what is going
on here...
joe
0 new messages