News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

wxSmith tutorial help needed

Started by DarthVega7, February 25, 2015, 06:54:22 PM

Previous topic - Next topic

DarthVega7

Hello,

I'm currently trying to complete this tutorial:  http://wiki.codeblocks.org/index.php?title=WxSmith_tutorial:_Using_wxPanel_resources

But I'm getting this error:

-------------- Build: Debug in wxTest6 (compiler: GNU GCC Compiler)---------------

mingw32-g++.exe -pipe -mthreads -D__GNUWIN32__ -D__WXMSW__ -DWXUSINGDLL -DwxUSE_UNICODE -Winvalid-pch -include wx_pch.h -DWX_PRECOMP -Wall -g -D__WXDEBUG__ -std=c++11 -IC:\SourceCode\Libraries\wxWidgets3.0\include -IC:\SourceCode\Libraries\wxWidgets3.0\lib\gcc_dll\mswud -c C:\Users\Josh\Documents\wxTest6\wxTest6App.cpp -o obj\Debug\wxTest6App.o
mingw32-g++.exe -pipe -mthreads -D__GNUWIN32__ -D__WXMSW__ -DWXUSINGDLL -DwxUSE_UNICODE -Winvalid-pch -include wx_pch.h -DWX_PRECOMP -Wall -g -D__WXDEBUG__ -std=c++11 -IC:\SourceCode\Libraries\wxWidgets3.0\include -IC:\SourceCode\Libraries\wxWidgets3.0\lib\gcc_dll\mswud -c C:\Users\Josh\Documents\wxTest6\wxTest6Main.cpp -o obj\Debug\wxTest6Main.o
mingw32-g++.exe -LC:\SourceCode\Libraries\wxWidgets3.0\lib\gcc_dll -o bin\Debug\wxTest6.exe obj\Debug\InternalPanel.o obj\Debug\wxTest6App.o obj\Debug\wxTest6Main.o  obj\Debug\resource.res -mthreads  -lwxmsw30ud -mwindows
obj\Debug\wxTest6Main.o: In function `ZN12wxTest6FrameC2EP8wxWindowi':
C:/Users/Josh/Documents/wxTest6/wxTest6Main.cpp:100: undefined reference to `wxTest6Frame::OnCustom1Paint(wxPaintEvent&)'
collect2.exe: error: ld returned 1 exit status
Process terminated with status 1 (0 minute(s), 1 second(s))
1 error(s), 0 warning(s) (0 minute(s), 1 second(s))


Line 100:

Custom1->Connect(wxEVT_PAINT,(wxObjectEventFunction)&wxTest6Frame::OnCustom1Paint,0,this);

oBFusCATed

You don't have a definition of this method in your code 99.9% sure.
If you have then inspect the compiler's log if the source file is really being compiled.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

DarthVega7

What do you mean definition of method?  I'm sorry I'm new to programming.

Quote from: oBFusCATed on February 25, 2015, 08:28:53 PM
You don't have a definition of this method in your code 99.9% sure.
If you have then inspect the compiler's log if the source file is really being compiled.

oBFusCATed

Good books on C/C++ explain what is a declaration and what is a definition.
If you don't know what these two terms mean you'll suffer a lot. So go reading.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]