Tabs & tcn_selchanging

Started by Paul D. Elliott, February 22, 2005, 02:24:52 PM

Previous topic - Next topic

Paul D. Elliott

Hi,

I'm still working on a program using the Tab control. I want the changing
of tabs to be strictly under program control. In the tcn_selchanging
routine for the tab control, if I exit the function with TRUE this is supposed
to cancel switching to a new tab ( and it does ). But the current tab gets
wiped of all info ( no buttons/entry fields/labels ). Am I supposed to
redisplay the current tab panel or is this something that FF should be
doing? And if it is me then how?

Thanks.

Paul D. Elliott

Paul,


If (@FF_pNotify.idFrom = IDC_PTS_TABCONTROL1) And (@FF_pNotify.Code = %TCN_SELCHANGING) Then
          ff = GetProp(HWND_PTS_TABCONTROL1, "FF_PTR")
          If ff Then FF_ControlIndex = @ff.ControlIndex Else FF_ControlIndex = -1
          FF_nResult = PTS_TABCONTROL1_TCN_SELCHANGING (FF_ControlIndex, hWndForm, @FF_pNotify.hwndFrom, lParam)
       If FF_nResult Then
           ShowWindow TCITEM.lParam, %SW_SHOW ' ***** FIX *******
           Function = FF_nResult
           Exit Function
       End If
       End If


Okay, I know you're busy.
in the routine that handles TCN_SELCHANGING, you need to add the
above line. You have already hidden the current tab but didn't take into
consideration that the programmer can chose to IGNORE the change so
that you must put back the current tab.
Would it be possible to get this in before the next release?

Thanks.

TechSupport

Thanks Paul, I will make the correction in the source code once I get back to my development computer. That was a good find - I appreciate it.