## How/where is wx/ defined for MSW? Topic is solved

If you are using the main C++ distribution of wxWidgets, Feel free to ask any question related to wxWidgets development here. This means questions regarding to C++ and wxWidgets, not compile problems.
jwpocid
In need of some credit
Posts: 6
Joined: Tue Nov 11, 2008 6:33 pm
Location: Pocatello, ID

### How/where is wx/ defined for MSW?

In getting my head around wxWidgets, I see that wc/ is used for almost all include file references. Yet the setup puts things in c:\wxWidgets-x.y.z directory...

How, when and where is wx/ defined as it is used in the various #include statements???? in Win/XP SP3??

It's gotta be something really obvious and all, but....I'm at a bit of a loss here.

ANY help someone can provide would be very greatly appreciated...

Thanks folks

Sof_T
Can't get richer than this
Posts: 864
Joined: Thu Jul 28, 2005 9:48 pm
Location: New Forest, United Kingdom
Contact:
What are using to compile it with? Generally I feed the wxWidgets include path to the compiler.
The home of Sof.T http://www.sof-t.site88.net/
Author of Programming with wxDevC++
http://sourceforge.net/projects/wxdevcpp-book/

jwpocid
In need of some credit
Posts: 6
Joined: Tue Nov 11, 2008 6:33 pm
Location: Pocatello, ID
I'm using Visual C++....I've tried it with both 2005 and 2008 versions.

timg
Earned some good credits
Posts: 148
Joined: Mon Jan 23, 2006 6:52 pm
You want to put it in the Project Properties under C++->General->Additional Include Directories

jwpocid
In need of some credit
Posts: 6
Joined: Tue Nov 11, 2008 6:33 pm
Location: Pocatello, ID
Thanks.
I checked my properties -- they're set as outlined for Visual C++. The include files all seem to have
#include "wx/<filespec>"
As it is installed, I have something like
c:\wxWidgets-2.8.9\include\wx\msw\<filespec>

So, I'm not clear how I would equate "wx" to be the
c:\wxWidgets-2.8.9\include\wx\msw\
????

DID I perhaps miss a step in installing things???

JimFairway
wxWorld Domination!
Posts: 1059
Joined: Sun Dec 30, 2007 6:40 pm
Hi,

Similar to other IDEs you have to tell the compiler where to find the additional include files.

Here's a link I found for yours:

http://msdn.microsoft.com/en-us/library/73f9s62w.aspx

Additional information is on the wiki, and probably worth a read because I'm sure it will save you time in the long run:
http://wiki.wxwidgets.org/MSVC_.NET_Set ... Properties

Navigate to the C++ compiler section and add an entry in the additional includes section as "c:\wxWidgets-2.8.9\include\".
I think the wiki suggests the use of an environment variable, but I believe what's above works until you move the directory!

Hope that helps,

Jim
OS: Vista SP1, wxWidgets 2.8.7.

jwpocid
In need of some credit
Posts: 6
Joined: Tue Nov 11, 2008 6:33 pm
Location: Pocatello, ID
Thank you so much...I thnk that may have done it.