Style of panel control

Discussion in 'ASP .Net' started by simon, May 14, 2004.

  1. simon

    simon Guest

    I have linkButton:
    <asp:LinkButton CommandArgument='<%#
    DataBinder.Eval(Container.DataItem,"con_ID") %>' CommandName="contact"
    ID=lnkContact Runat=server><li><%#
    DataBinder.Eval(Container.DataItem,"contact") %></li></asp:LinkButton>

    and panel:

    <asp:panel style="position:absolute;top:100;left:100" Width=300 Height=300
    Runat=server ID=pnlContact Visible=False></asp:panel>

    on the page.
    When user clicks this link button I show the panel:

    pnlContact.visible=true

    Now I would like to set the left and top parameter of panel style to be the
    same as position of link button on the page.

    How can I do that?

    Thank you,
    Simon
    simon, May 14, 2004
    #1
    1. Advertising

  2. simon

    avnrao Guest

    there are many ways to achieve this..

    set your page to flow layout. MS_POSITIONING="FlowLayout" for the body tag.
    and place the link button inside a panel. set the link button panel visible
    to false and the other panel to true.

    or in design mode, drag/drop link button and panel one on to other..

    or set left/top positions for link button initially. and
    RegisterStartupScript to get left/top positions and assign them to panel.

    Av.


    "simon" <> wrote in message
    news:%23x%...
    >I have linkButton:
    > <asp:LinkButton CommandArgument='<%#
    > DataBinder.Eval(Container.DataItem,"con_ID") %>' CommandName="contact"
    > ID=lnkContact Runat=server><li><%#
    > DataBinder.Eval(Container.DataItem,"contact") %></li></asp:LinkButton>
    >
    > and panel:
    >
    > <asp:panel style="position:absolute;top:100;left:100" Width=300 Height=300
    > Runat=server ID=pnlContact Visible=False></asp:panel>
    >
    > on the page.
    > When user clicks this link button I show the panel:
    >
    > pnlContact.visible=true
    >
    > Now I would like to set the left and top parameter of panel style to be
    > the
    > same as position of link button on the page.
    >
    > How can I do that?
    >
    > Thank you,
    > Simon
    >
    >
    avnrao, May 14, 2004
    #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. Harry
    Replies:
    3
    Views:
    541
    Harry Singh
    Nov 10, 2003
  2. HS1
    Replies:
    3
    Views:
    486
  3. Ulf Meinhardt
    Replies:
    0
    Views:
    609
    Ulf Meinhardt
    Jul 7, 2009
  4. Robin Wenger
    Replies:
    0
    Views:
    2,926
    Robin Wenger
    Aug 18, 2011
  5. Ken Varn
    Replies:
    0
    Views:
    443
    Ken Varn
    Apr 26, 2004
Loading...

Share This Page