PlanetSquires Forums

Support Forums => Other Software and Code => Topic started by: Martin Francom on December 06, 2009, 10:24:08 PM

Title: Need help with FireSplitter
Post by: Martin Francom on December 06, 2009, 10:24:08 PM
Need help with the syntax for selecting which child Form I want in the particular pane in FireSplitter control.

I want to click a button and be able to change the child form being displayed inthe FireSpliter control.   How would I do this?
Title: Re: Need help with FireSplitter
Post by: Paul Squires on December 06, 2009, 10:32:33 PM
Check out the FireSplitter.inc source code for the control. You will see a message called %FF_SPLITTER_SETCHILD

SendMessage HWND_FORM1_SPLITTER1, %FF_SPLITTER_SETCHILD, nPanelNum, hWndChildPage

nPanelNum = 1, 2, or 3.
hWndChildPage would be the windows handle of a non-modal child form that you want to display in the panel.
Title: Re: Need help with FireSplitter
Post by: Martin Francom on December 06, 2009, 10:44:03 PM
Paul,
  Thanks for the help.  I give that a try.  I looked in the Functions Library, even did a search, I could not find anything about any of the Fire-Controls. Am I looking in the wrong area?
Title: Re: Need help with FireSplitter
Post by: Martin Francom on December 06, 2009, 11:11:14 PM
Ok,
   This compiles:
    SendMessage HWND_FRMMAIN_FIRESPLITTER1, %FF_SPLITTER_SETCHILD, 1, HWND_FORMDOCINFO

But the form doesn't change when the button's clicked.  Is there something more that I need to do?

The FRMMAIN has just the FireSpliter control on it. the FireSplitter has just two panes. I assume they are 1 & 2.    The initital child forms have been set in the FireSpliter control.  They display correctly.  The Child form in the left pane has a few buttons on it.  The Child form on the right is the one I want to change when the button is clicked.  The buttons action function containss:


Function FORMCNTRLS_CMDDRSCRN_BN_CLICKED ( _
                                         ControlIndex     As Long,  _  ' index in Control Array
                                         hWndForm         As Dword, _  ' handle of Form
                                         hWndControl      As Dword, _  ' handle of Control
                                         idButtonControl  As Long   _  ' identifier of button
                                         ) As Long


     SendMessage HWND_FRMMAIN_FIRESPLITTER1, %FF_SPLITTER_SETCHILD, 1, HWND_FORMDOCINFO

End Function

   
Title: Re: Need help with FireSplitter
Post by: Eddy Van Esch on December 07, 2009, 05:21:33 AM
Marty,

Do you also notice the behaviour I described here?
http://www.planetsquires.com/protect/forum/index.php?topic=2159.0

Kind regards
Title: Re: Need help with FireSplitter
Post by: Martin Francom on December 07, 2009, 06:46:24 PM
Quote from: Eddy Van Esch on December 07, 2009, 05:21:33 AM
Marty,

Do you also notice the behaviour I described here?
http://www.planetsquires.com/protect/forum/index.php?topic=2159.0

Kind regards


Eddy,  No.  I just did a quick check for that problem.  My program functions correctly with reguards the buttons on the child form.
Title: Re: Need help with FireSplitter
Post by: Paul Squires on December 07, 2009, 08:47:07 PM
The problem will happen if you put another control on the Main form that the Splitter control is on. I am examining some generated source code now to see if I can determine why that happens. Very weird.