I have a UI where the user selects "menu" items from an explorer bar on the left, tabs are displayed on the right (a splitter holds both). tabs are opened to contai child forms for each action.
When the user hits "save" on a child form in a tab I want to close the tab. I can call a javascript function on the parent form with the relevant details (not having a Key property for each tab is a problem, though it can be worked around - and this is necessary because I have no control over the order in which tabs will be created or destroyed - so the index is useless)
However I need to close the tab. there doesn't seem to be a method for this? Errr, this is a rather large functional hole if its true - can anyone enlighten me?
(The curent workaround is ugly - I have to trigger a postback)
Hello Peter,
You can create a tab on the client with the method addTab:
tab.addTab("title", "http://infragistics.com", true);
tab.addTab("title ", "Default2.aspx", true);
Regards,
Lyuba Petrova
Developer Support Engineer
Infragistics
www.infragistics.com/support
That does work, thanks.
however, the tab that is created has a FIXED width "tab" - and setting a title as simple as "Project Step" results in the X for the closing button overlapping the word "step". Something is not autosizing correctly here!??
I asume this is a bug, is there a workaround?
The same thing happens if you create a tab with Hidden=true in the markup. When its made visible, it isn't rendering correctly.
oh, Webtab.get_tabs().get_length() somes up as not supported. You have to use Webtab.get_tabs().length - I assume there is a mistake somewhere in a method definition as this isn't consistent with the resto f the framework?
If you play with this some odd internal javascript erros crop up too, but I haven't worked out if they are on my end yet
And there is no method for removing the Close X button on the tab if its already present (ie: a set_enableCloseButton method for instance) Although realisically these should be divided into sep properties for Enabled(which exist) and CloseButton (which do not)
The markup (+Hidden) works, but only if I do NOT want the close button to be present...sigh