954,593 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

help in displaying multiple tabs in same webpage

Hi i am new to asp.net.
i am preparing an asp.net application which is of like this
it will have a webpage,which consists of multiple tabs
when i click on each tab it will display different information in the same webpage.

my problem is how to create a multiple tab webpage
is there any control available in asp.net?
or i need to download any third party tool?

thanks in advance
naresh

Nareshp_123
Newbie Poster
18 posts since Nov 2007
Reputation Points: 10
Solved Threads: 0
 

i dont know of any third party tabs but when i need tabs i use iframes. with a form for each page you want in each then use javascript to change the page.

Fungus1487
Posting Pro in Training
459 posts since Apr 2007
Reputation Points: 66
Solved Threads: 56
 

there are tabs via asp.net controls, but they are for IE and do not work well in orther browsers. Your best bet, if you wish to use tabs, is to either use AJAX methods or plain old Javascript. This way the user downloads all the information in the tabs on the same page, and you use javascript to dynamically hide divs, enable other divs, and set certain colors accordingly. This is best for cross-browser compatability, but requires coding on your end. If you wish to use the IE way with asp.net, then you will need to use asp:Menu controls and asp:View controls. Otherwise, follow a demo here from 4guysfromrolla

http://aspnet.4guysfromrolla.com/articles/092204-1.aspx

SheSaidImaPregy
Veteran Poster
1,080 posts since Sep 2007
Reputation Points: 43
Solved Threads: 68
 

Thanks a lot Fungus1487,SheSaidImaPregy .
SheSaidImaPregy had provided an example link which i had gone through i'll check it whether i can make it in similar fashion.

Nareshp_123
Newbie Poster
18 posts since Nov 2007
Reputation Points: 10
Solved Threads: 0
 

I created tab by combining Multiview and View

Kusno
Junior Poster
191 posts since Aug 2007
Reputation Points: 11
Solved Threads: 17
 
I created tab by combining Multiview and View

hi kusno

can you please send me if you have any example .
as
SheSaidImaPregy has given a link which has tabs vertical in a page .but i need to display in horizantal format similar to this link http://www.abb.com/

i am trying to modify the same thing what SheSaidImaPregy had sent hope it works.

Nareshp_123
Newbie Poster
18 posts since Nov 2007
Reputation Points: 10
Solved Threads: 0
 
SheSaidImaPregy
Veteran Poster
1,080 posts since Sep 2007
Reputation Points: 43
Solved Threads: 68
 

My code is same as SheSaidImaPregy's link.

I use Anthem control, but you don't use Anthem, you could change it to ASP.Net control







Sub SetButtonColor (ByVal TransType As String)
If TransType = "FX" Then
CmdFX.BackColor = Drawing.Color.Yellow
CmdFX.Font.Bold = True
CmdFX.ForeColor = Drawing.Color.IndianRed

CmdIBD.BackColor = Drawing.Color.PaleTurquoise
CmdIBD.Font.Bold = False
CmdIBD.ForeColor = Drawing.Color.Blue
ElseIf TransType = "IBD" Then
CmdFX.BackColor = Drawing.Color.PaleTurquoise
CmdFX.Font.Bold = False
CmdFX.ForeColor = Drawing.Color.Blue

CmdIBD.BackColor = Drawing.Color.Yellow
CmdIBD.Font.Bold = True
CmdIBD.ForeColor = Drawing.Color.IndianRed
End If
End Sub

Protected Sub CmdFX_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles CmdFX.Click
MVBLS.ActiveViewIndex = 1
SetButtonClick("FX")
FillFXData()
End Sub

Protected Sub CmdFX_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles CmdFX.Click
MVBLS.ActiveViewIndex = 1
SetButtonClick ("FX")
FillIBDData()
End Sub

Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Page.SetFocus(Page)
Page.MaintainScrollPositionOnPostBack = True

If Not IsPostBack Then
MVBLS.ActiveViewIndex = 0
SetButtonColor ("IBD")
FillIBDData()
End If
End Sub

Kusno
Junior Poster
191 posts since Aug 2007
Reputation Points: 11
Solved Threads: 17
 

there seems to be alot of processing on the server to simly just change these pages why not use CSS css tabs with iframes then just load your aspx page into the iframe on tab change, not only would it be complient across all modern browsers but it would save pointless postbacks.

Fungus1487
Posting Pro in Training
459 posts since Apr 2007
Reputation Points: 66
Solved Threads: 56
 

Makes you use multiple pages, but besides that, it is better to use the css tabs.

SheSaidImaPregy
Veteran Poster
1,080 posts since Sep 2007
Reputation Points: 43
Solved Threads: 68
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You