Click here to Skip to main content
15,897,334 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi how can I create the tabs in asp.net by c# ?

I tried to put the html code of tabs direct in aspx page but it gave me an error
A Simple ASP.NET Tab Control Using the MultiView control[^]
can anyone help me?
thank yu
Posted
Updated 25-Apr-11 12:36pm
v2
Comments
Manfred Rudolf Bihy 25-Apr-11 18:22pm    
What error? Can we see the relevant bits of code that are causing the error.
Be more specific and elaborate on the problem you're observing.
at all 25-Apr-11 18:26pm    
the editing of my post did not work?
what is the problem

1 solution

Here[^]is an example and how you can use Tabs control from Ajax Control Tool kit.

Another exapmle link from CP;
Using ASP.NET AJAX TAB Control[^]
 
Share this answer
 
Comments
at all 25-Apr-11 18:44pm    
your first example after edit it as

<ajaxToolkit:TabContainer ID="TabContainer1" runat="server"> <ajaxToolkit:TabPanel ID="TabPanel1" runat="server"> <HeaderTemplate>Tab1</HeaderTemplate> <contenttemplate>Content under Tab1 <ajaxToolkit:TabPanel ID="TabPanel2" runat="server"> <HeaderTemplate>Tab2</HeaderTemplate> <contenttemplate>Content under Tab2 <ajaxToolkit:TabPanel ID="TabPanel3" runat="server"> <HeaderTemplate>Tab3</HeaderTemplate> <contenttemplate>Content under Tab3

it is not work?
Orcun Iyigun 25-Apr-11 18:59pm    
You have to be more specific. It is not working is not acceptable. But I think that you dont have the AJAX toolkit library. From here download it: http://www.asp.net/ajaxlibrary/download.ashx , then you should include it your toolbox. In order to do this, right click on your toolbox then got o "Choose items", click browse and find the toolkit library there and then add it.
at all 25-Apr-11 19:21pm    
I downloaded before , to be more specific
the error is when I change to design page ,instead of show me the tabs it shows me this statment (error creating control-TableContainer 1 ,this control cannt be displayed because its Tapprefix is not registred in this web form)?
Orcun Iyigun 25-Apr-11 19:51pm    
you have to include it in the page, place this code to top your aspx page.
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>, google is your best friend next time try using it.
at all 26-Apr-11 14:29pm    
what is TagPrefix means?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900