Layout issues with MultiView control/tabbed display

Discussion in 'ASP .Net Web Controls' started by paul.gibson@abbott.com, Dec 5, 2007.

  1. Guest

    Hi all -

    I'm using version 2.0 of the framework. Using a Multiview control to
    produce a tabbed display. I'm putting two Panels in each View, one
    for the "tabs", one for the content. The mark-up looks something
    like:

    <asp:MultiView ID="mvMain" runat="server" ActiveViewIndex="0">
    <asp:View ID="View1" runat="server">
    <asp:panel ID="PanelNavView1" runat="server">
    <asp:Label ID="lblView1" runat="server"
    Text="Tab&nbsp;for&nbsp;View1"></asp:Label>
    <asp:LinkButton ID="lbView2FromView1"
    runat="server">Tab&nbsp;for&nbsp;View2</asp:LinkButton>
    <asp:LinkButton ID="lbView3FromView1"
    runat="server">Tab&nbsp;for&nbsp;View3</asp:LinkButton>
    <asp:LinkButton ID="lbView4FromView1"
    runat="server">Tab&nbsp;for&nbsp;View4</asp:LinkButton>
    <asp:LinkButton ID="lbView5FromView1"
    runat="server">Tab&nbsp;for&nbsp;View5</asp:LinkButton>
    <asp:LinkButton ID="lbView6FromView1"
    runat="server">Tab&nbsp;for&nbsp;View6</asp:LinkButton>
    </asp:panel>
    <asp:panel ID="panelView1" runat="server">
    This is the content for view 1
    </asp:panel>
    </asp:View>
    <asp:View ID="View2" runat="server">
     
    , Dec 5, 2007
    #1
    1. Advertising

  2. John Padilla Guest

    It would be easier for you to get a free tabbed control or create one of your
    own ad the multiview is just that a multivlew. placing a tab strip like
    control above the multivkew that supports wrapping of the tabs is the way to
    go. Try CodePlex, The Code Project or search google and i am sure you will
    find either a free control or a arcticle on how to build this.

    Hope this helps!

    "" wrote:

    > Hi all -
    >
    > I'm using version 2.0 of the framework. Using a Multiview control to
    > produce a tabbed display. I'm putting two Panels in each View, one
    > for the "tabs", one for the content. The mark-up looks something
    > like:
    >
    > <asp:MultiView ID="mvMain" runat="server" ActiveViewIndex="0">
    > <asp:View ID="View1" runat="server">
    > <asp:panel ID="PanelNavView1" runat="server">
    > <asp:Label ID="lblView1" runat="server"
    > Text="Tab for View1"></asp:Label>
    > <asp:LinkButton ID="lbView2FromView1"
    > runat="server">Tab for View2</asp:LinkButton>
    > <asp:LinkButton ID="lbView3FromView1"
    > runat="server">Tab for View3</asp:LinkButton>
    > <asp:LinkButton ID="lbView4FromView1"
    > runat="server">Tab for View4</asp:LinkButton>
    > <asp:LinkButton ID="lbView5FromView1"
    > runat="server">Tab for View5</asp:LinkButton>
    > <asp:LinkButton ID="lbView6FromView1"
    > runat="server">Tab for View6</asp:LinkButton>
    > </asp:panel>
    > <asp:panel ID="panelView1" runat="server">
    > This is the content for view 1
    > </asp:panel>
    > </asp:View>
    > <asp:View ID="View2" runat="server">
    > .
    > .
    > .
    > </asp:View>
    > </asp:MultiView>
    >
    > I apply some styling to make the "tabs" look the way I want (I took
    > out the CssClass= stuff in the markup) and it looks fine when the
    > "tabs" are displayed side-by-side. When there is insufficient room to
    > display the "tabs" side-by-side, I would like them to wrap into one or
    > more rows of tabs. I can also make them do this fine. The issue I am
    > having is that unless I take away all border-top and padding-top from
    > the Label and LinkButton controls, the "tabs" in the bottom row
    > partially cover the "tabs" in the top row (assuming 2 rows, here).
    > Adding a top or bottom margin has not helped me nor has a number of
    > other stabs in the dark. I'm a relative newbie to CSS/styling but I
    > suspect my problem has something to do with the LinkButtons being
    > converted to anchors <a> in the page that is output.
    >
    > Can anyone lend a hand?
    >
    > TIA
    >
    > Paul
    >
     
    John Padilla, Dec 15, 2007
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    1
    Views:
    644
    John Timney \(MVP\)
    Jun 19, 2006
  2. Brad Isaacs

    Menu Control with Multiview Control ???

    Brad Isaacs, Feb 8, 2007, in forum: ASP .Net
    Replies:
    5
    Views:
    855
    Brad Isaacs
    Feb 9, 2007
  3. Bit Byte
    Replies:
    1
    Views:
    621
    Toby Inkster
    Nov 21, 2006
  4. Yin99
    Replies:
    1
    Views:
    483
    =?Utf-8?B?TmF0aGFuaWVsIEdyZWVuZQ==?=
    Aug 20, 2007
  5. Andy B
    Replies:
    0
    Views:
    394
    Andy B
    Dec 29, 2008
Loading...

Share This Page