wxHelpController problem 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.
Post Reply
wangbo_coldwind
Knows some wx things
Knows some wx things
Posts: 38
Joined: Thu Jun 09, 2005 1:44 am
Location: china

wxHelpController problem

Post by wangbo_coldwind »

Hi, when I use wxHelpContorller, it always crash when I exit the problem, even if I did nothing,but just create a wxFrame.
such as:

wxHelpController m_help;

Code: Select all

MyAPP :public wxApp
{
  bool  OnInit()
  {
    m_help.Initialize("help.hlp");
    m_myframe = new wxFrame(...);
  }

  int onExit()
  {
    return 0;
  }
}
upCASE
Moderator
Moderator
Posts: 3176
Joined: Mon Aug 30, 2004 6:55 am
Location: Germany, Cologne

Post by upCASE »

Hi!
Try it like this

Code: Select all

MyAPP :public wxApp
{
    wxHelpController m_help;
    
    bool OnInit()
   {
        m_help.Initialize("help.hlp");
        m_myframe = new wxFrame(...);
        return true;
   }

}
OS: OpenSuSE, Ubuntu, Win XP Pro
wx: svn
Compiler: gcc 4.5.1, VC 2008, eVC 4

"If it was hard to write it should be hard to read..." - the unknown coder
"Try not! Do. Or do not. There is no try." - Yoda
wangbo_coldwind
Knows some wx things
Knows some wx things
Posts: 38
Joined: Thu Jun 09, 2005 1:44 am
Location: china

Post by wangbo_coldwind »

thanks very much, it really works, but why can't I put the m_help outside,in wx2.4.2,it works very will, while in 2.6,it can't work

Thanks again.
Post Reply