Author Topic: Can't use wxFormBuilder with Code::Blocks  (Read 21705 times)

Offline passerby

  • Single posting newcomer
  • *
  • Posts: 8
Can't use wxFormBuilder with Code::Blocks
« on: July 27, 2008, 05:31:46 pm »
I have installed Code::Blocks and wxFormBuilder
Then started a new project and selected wxFormBuilder for GUI tool.
The new project wizard finished fine, but I don't see a way to use wxFormBuilder (unlike wxSMith, but I'd like to use wxFB).

How can I make Code:Blocksr recognize the installed wxFormBuilder?

Sorry for the probably dumb question, I am pretty new to all this.

Running Ubuntu Hardy Heron under VirtualBox on PCLinuxOS.

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: Can't use wxFormBuilder with Code::Blocks
« Reply #1 on: August 11, 2008, 03:27:53 pm »
The new project wizard finished fine, but I don't see a way to use wxFormBuilder
wxFormBuilder is a stand-alone application that cannot be integrated into C::B directly (as wxSmith which is a plugin). You need to run it as an external application (and may continue editing the code with C::B).
You may want to add wxFormBuilder as a tool in the tools menu of C::B. this way you can easily launch it from within C::B and within the right folder and with the right options.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline passerby

  • Single posting newcomer
  • *
  • Posts: 8
Re: Can't use wxFormBuilder with Code::Blocks
« Reply #2 on: September 25, 2008, 09:36:47 pm »
Thanks for the tip.

After a long pause I am having another go at it.
I added wxFormBuilder as a tool as suggested, and created a new dialog-based project.
Running the new project brings up the dialog with 'Welcome to wxWidgets'.
Double-clicking on WxWizDialog.fbp in the Others folder within Code::Blocks starts up wxFormBuilder.
As a timid test, I re-wrote the message text to 'Hiho' in wxFormBuilder, then saved.
Returned to C::B, rebuilt, and ran the program -- and it STILL displays the original message.

What am I doing wrong?

Offline alb_cb_moon

  • Multiple posting newcomer
  • *
  • Posts: 25
Re: Can't use wxFormBuilder with Code::Blocks
« Reply #3 on: September 25, 2008, 10:13:42 pm »
You need not only "saved the project" , select "Generate Code" option too
OS: Windows XP SP2
GUI Library: wxWidgets 2.8.10
IDE: CodeBlocks SVN / Nigth Builds Compiler: MinGW & gcc 3.4.5

Offline passerby

  • Single posting newcomer
  • *
  • Posts: 8
Re: Can't use wxFormBuilder with Code::Blocks
« Reply #4 on: September 26, 2008, 11:42:07 am »
alb_cb_moon,
Thank you, but I still have a problem...
This is a wxWidgets project that starts with an auto-generated code.
wxFormBuilder said it needed to convert the code. Accepting that, generating the code, saving, and trying to build in Code::Blocks now produces a build error:
Code
'wxMessageBox' was not declared in this scope'
I reinstalled everything as described at http://wxpack.sourceforge.net/Tutorials/CodeBlocks, but still get the same error.

Edit: Sorry, didn't generate inherited class... Works fine now.
Thanks for helping.
« Last Edit: September 26, 2008, 12:19:14 pm by passerby »

Offline jonas thomas

  • Multiple posting newcomer
  • *
  • Posts: 18
Re: Can't use wxFormBuilder with Code::Blocks
« Reply #5 on: November 29, 2008, 03:33:30 pm »
You may want to add wxFormBuilder as a tool in the tools menu of C::B. this way you can easily launch it from within C::B and within the right folder and with the right options.
Please forgive this newbie question.
What is considered good practice for configuring wxformbuilder  as a user defined tool within Code::blocks for within either Linux or XP? (I plan to be doing both)
This seems to work in Linux, but at this point I'm not even claiming to know what I'm doing.
Are these considered to be the "right options"? :?