Two suggestions for Tab Strip

Started by velasquez, March 27, 2011, 06:42:07 AM

Previous topic - Next topic

velasquez

1 - (defun c:Untitled_Form1_TabStrip1_OnSelChanging (ItemIndex [as Long] NewItemIndex [as Long] /))
ItemIndex is the index of the currently selected tab.
NewItenIndex shows the index of the new selection.
It would be nice to have this information in a single event.

2 - (dcl_TabStrip_GetTabCaption Untitled_Form1_TabStrip1 TabIndex [as Long])

Velasquez

owenwengerd

Unfortunately, the Windows tab control's TCN_SELCHANGING notification does not include the tab that is being activated, so there would be no way of implementing your request using the built-in notifications.

Regarding your second suggestion, you can easily do that on your own:
Code (autolisp) Select
(defun GetTabCaption ( control tabindex )
  (nth tabindex (dcl_Control_GetTabCaptionList control))
)

Owen Wengerd (Outside The Box) / ManuSoft