This is a migrated thread and some comments may be shown as answers.

[Solved] TabStrip with Custom Menu

2 Answers 107 Views
TabStrip
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Ankit
Top achievements
Rank 1
Ankit asked on 21 Jun 2011, 01:22 PM
Is it possible to create a Custom Menu in TabStrip like the one in Menu with a Drop down and have Close Icon and a Maximize icon to close and maximize a TabStrip's Content ?

2 Answers, 1 is accepted

Sort by
0
Mohamad
Top achievements
Rank 1
answered on 01 Jul 2011, 09:43 AM
hello
have you find the solution ?
i need close button in the tab strip in my project
0
John DeVight
Top achievements
Rank 1
answered on 06 Jul 2011, 01:36 PM
I've been developing a client api for the Telerik Extensions for MVC and one of the functions that I have created is a removeTab() function.  I have updated a sample application to show how a button can be added to the top right corner of the tab that, when clicked, will call  the removeTab() function to remove the tab from the tabstrip.  I've attached the sample project.

To run the sample application, you will need to add the Telerik "Content" and "Scripts" folders back into the project for the version of Telerik Extensions that you are using.  Run the application and in the "Samples List" click on the "Add and Remove Tabs" link under "TabStrip".

How it works:
1. I added an image to the project at: /Content/tab-close.gif
2. I added a style called "a.tab-close" to  /Content/Site.css
3. In the /Views/TabStrip/AddRemoveTabs.cshtml, I added the "OnLoad" client event to the TabStrip to add an anchor element with the tab-close css class that, when clicked, will call the closeTab() function.  The closeTab() function calls the removeTab() function and removes the tab.

Let me know whether this worked for you.  In the meantime, I will be updating the Telerik Extensions For ASP.NET MVC : Extended Client API project on CodePlex to incorporate this feature.

Regards,

John DeVight
Tags
TabStrip
Asked by
Ankit
Top achievements
Rank 1
Answers by
Mohamad
Top achievements
Rank 1
John DeVight
Top achievements
Rank 1
Share this question
or