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

Can I simulate clicking on tab?

8 Answers 251 Views
TabStrip
This is a migrated thread and some comments may be shown as answers.
Andreja Zitnik
Top achievements
Rank 1
Andreja Zitnik asked on 27 Jan 2010, 12:34 PM
Hi,

I have a RadTreeView and a RadTabStrip. When I click on a tab, some content displays below it in a PlaceHolder.
I would also like for some nodes in RadTreeView to do exactly the same - for example node Stations would select tab Stations (I already figured out how to do this using JavaScript) and I also want it to display the content that goes with the tab, but nothing shows up
.
When I do tab.select() in JavaScript, the correct tab is selected, but there is no postback. How can I make the tab do a postback so that effect will be the same as clicking on it?

Thank you,
Andrea

8 Answers, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 27 Jan 2010, 02:11 PM
Hi Andreja Zitnik,

All Telerik controls for navigation expose a click() client method for their items(nodes or tabs). You can view a demonstration of this method which causes a server side postback here:
http://www.telerik.com/support/kb/aspnet-ajax/window/using-radprompt-and-radconfirm-with-telerik-navigational-controls.aspx

Kind regards,
Peter
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Andreja Zitnik
Top achievements
Rank 1
answered on 27 Jan 2010, 10:50 PM
I actually tried tab.click(), but because I did a tab.select() before that, it didn't do anything. Well, it works now :)

Thank you,
Andrea
0
Gabriela
Top achievements
Rank 1
answered on 17 May 2014, 09:18 PM
Hi,

I have an issue regarding a tabstrip with 3 tabs, using MVC. I am trying to load 'in advance' the content of tab2 and tab3 when tab1 is loading (to reduce the time spent at loading if the user remains more on tab1).

I have seen in this thread you recommend the tab.click() method, can you provide a short example on how to use this, suitable for my scenario? In the previous example (http://www.telerik.com/support/kb/aspnet-ajax/details/using-radprompt-and-radconfirm-with-telerik-navigational-controls) there is no real reference to the tabstrip control.

Thank you.

Best regards,
Gabriela
0
Nencho
Telerik team
answered on 22 May 2014, 07:18 AM
Hello Gabriela,

I have prepared a sample page for you, base on the referenced article and implementing the solution using the RadTabStrip control. You could find it attached and test the behavior at your end.

Regards,
Nencho
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Gabriela
Top achievements
Rank 1
answered on 22 May 2014, 03:34 PM
Hi Nencho,

Thank you for the example you provided.
Can you please let me know if there is any way to check if a tab in the TabStrip has been fully loaded. From what I see, we can only use OnLoad, OnError, OnSelect and OnContentLoad events. I would need to be able to command loading a tab only after another one has been fully loaded. I don't know the duration of loading each tab (otherwise I would have used a setTimeout function).

Thank you.

Best regards,
Gabriela
0
Nencho
Telerik team
answered on 27 May 2014, 11:48 AM
Hello Gabriela,

You could use the OnClientLoad client-side event to capture when the control and the Tabs are fully initialized on the client. Could you specify what concerns do you have, regarding the usage of this even?

Regards,
Nencho
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Gabriela
Top achievements
Rank 1
answered on 05 Jun 2014, 01:05 PM
Hi Nencho,

I am using a Telerik TabStrip, not a RadTabStrip, therefore I don't have the OnClientLoad event available.

Best regards,
Gabriela
0
Sebastian
Telerik team
answered on 09 Jun 2014, 08:52 AM
Hello Gabriela,

What do you mean by Telerik TabStrip in this case - the tabstrip widget from our Telerik UI for ASP.NET MVC suite? If so, you may be interested in reviewing this example:
http://demos.telerik.com/aspnet-mvc/tabstrip/ajax

Furthermore, for additional customizations you can use the document.ready handler where the tabstrip widget is already fully loaded. See the html version of the same demo for reference:
http://demos.telerik.com/kendo-ui/tabstrip/ajax

Regards,
Sebastian
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
TabStrip
Asked by
Andreja Zitnik
Top achievements
Rank 1
Answers by
Peter
Telerik team
Andreja Zitnik
Top achievements
Rank 1
Gabriela
Top achievements
Rank 1
Nencho
Telerik team
Sebastian
Telerik team
Share this question
or