OpenDCL Forums

OpenDCL => Runtime/AutoLISP => Topic started by: velasquez on March 27, 2011, 06:42:07 AM

Title: Two suggestions for Tab Strip
Post by: velasquez on March 27, 2011, 06:42:07 AM
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
Title: Re: Two suggestions for Tab Strip
Post by: owenwengerd on March 27, 2011, 07:48:17 PM
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))
)