easy but weird question.

2 posts, 0 answers
  1. mathieu cupryk
    mathieu cupryk avatar
    27 posts
    Member since:
    Jul 2009

    Posted 16 Dec 2009 Link to this post

    I have a panel bar with a button outside the radajaxpanel. If I click the button it will goto another radpanelitem. and then come back to the save button behind code.

    What I need to do is that if this button is clicked. Put a value in a session variable?

     

    <telerik:RadPageView ID="RadPageView2" runat="server">

     

     

    <telerik:RadAjaxPanel ID="RadAjaxPanel2" runat="server">

     

     

    <telerik:RadPanelBar ID="RadPanelBar2"

     

     

    OnItemDataBound="RadPanelBar2_ItemDataBound" runat="server" Skin="WebBlue"

     

     

    ExpandMode="FullExpandedItem" Height="550px" Style= "position: static; border:0px"

     

     

    Width="100%" oninit="RadPanelBar2_Init"

     

     

    onitemclick="RadPanelBar2_ItemClick" onload="RadPanelBar2_Load">

     

     

    <Items>

     

     

    <telerik:RadPanelItem runat="server" Text="GENERAL INFORMATION" Font-Bold="true"

     

     

    Expanded="true">

     

     

    <Items>

     

     

    <telerik:RadPanelItem Height="350px" Value="GeneralInformation" runat="server">

     

     

    <ItemTemplate>

     

     

    <uc2:ctrlAboutMe ID="ctrlAboutMe" runat="server" />

     

     

    <uc5:ctrlVisitorInformation ID="ctrlVisitorInformation" runat="server" />

     

     

    </ItemTemplate>

     

     

    </telerik:RadPanelItem>

     

     

    </Items>

     

     

    </telerik:RadPanelItem>

     

     

    <telerik:RadPanelItem runat="server" Text="PHYSICAL CHARACTERISTICS" Font-Bold="true">

     

     

    <Items>

     

     

    <telerik:RadPanelItem Value="PhysicalAttributes" runat="server">

     

     

    <ItemTemplate>

     

     

    <uc3:ctrlPhysicalAttributes ID="ctrlPhysicalAttributes" runat="server" />

     

     

    </ItemTemplate>

     

     

    </telerik:RadPanelItem>

     

     

    </Items>

     

     

    </telerik:RadPanelItem>

     

     

    <telerik:RadPanelItem runat="server" Text="LIFESYLE AND HABBITS" Font-Bold="true">

     

     

    <Items>

     

     

    <telerik:RadPanelItem Value="LifeStyle" runat="server">

     

     

    <ItemTemplate>

     

     

    <uc4:ctrlLifeStyle ID="ctrlLifeStyle" runat="server" />

     

     

    </ItemTemplate>

     

     

    </telerik:RadPanelItem>

     

     

    </Items>

     

     

    </telerik:RadPanelItem>

     

     

    <telerik:RadPanelItem runat="server" Text="RELATIONSHIPS AND CHILDREN" Font-Bold="true">

     

     

    <Items>

     

     

    <telerik:RadPanelItem Value="RelationshipChildren" runat="server">

     

     

    <ItemTemplate>

     

     

    <uc6:ctrlRelationshipChildren ID="ctrlRelationshipChildren" runat="server" />

     

     

    </ItemTemplate>

     

     

    </telerik:RadPanelItem>

     

     

    </Items>

     

     

    </telerik:RadPanelItem>

     

     

    </Items>

     

     

    </telerik:RadPanelBar>

     

     

    </telerik:RadAjaxPanel>

     

     

    <br />

     

     

    <div align="center">

     

     

    <asp:Label ID="lblProfileMessage" runat="server" Text=""></asp:Label>

     

     

    <br />

     

     

    <asp:ImageButton ID="SaveButton" OnClick="SaveButton_Click" runat="server" Visible="true"

     

     

    ImageUrl="~/Images/Buttons/updatesilver.gif" />

     

     

    <br />

     

     

    <br />

     

     

    </div>

     

     

    </telerik:RadPageView>

     


  2. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 17 Dec 2009 Link to this post

    Hello,

    I am not quite sure about the scenario that you are trying. I guess you want to set the panelbaritem Expanded and save the corresponding value in session. If so you are try the following code.

    CS:
     
        protected void SaveButton_Click(object sender, EventArgs e) 
        { 
            panelmenu1.FindItemByText("GENERAL INFORMATION").Expanded = true// Set the panelbar as expanded 
            string str = "value"
            Session["value"] = str; // Set the value 
        } 

    Could you explain the requirement a bit more, if this does not help?

    -Shinu.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top