Assign a property to webcontrol in run-time

Discussion in 'ASP .Net' started by Andrea, Jun 1, 2006.

  1. Andrea

    Andrea Guest

    I've built my own webcontrol to make page navigation.
    One of control's property is recordCount that is used to know how many record
    should be take in mind to print out the pages number.

    The question is

    I've registered the control in the page in this way
    <%@ Register Assembly="WebControls.PageNavigationBar" Namespace="WebControls"
    TagPrefix="cc1" %>

    and added a a declaration like this

    <cc1:pagenavigationbar id="PageNavigationBar1" runat="server" ></cc1:pagenavigationbar>

    but how can I modify dinamically the property in page's code.

    Simply trying to write cc1 or PageNavigationBar won't give the expected result
    so this mean that this is not the right way.

    Where Am I doing mistakes?

    Thanks
    Andre
    Andrea, Jun 1, 2006
    #1
    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. Pavils Jurjans

    Assign session onEnd event handler at run-time

    Pavils Jurjans, Apr 21, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    2,525
    Pavils Jurjans
    Apr 21, 2004
  2. Frédéric Mayot

    Cannot assign property of a WebControl

    Frédéric Mayot, Aug 8, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    357
    Alan Ferrandiz [MCT]
    Aug 8, 2004
  3. Dave R
    Replies:
    7
    Views:
    15,160
    Matt Berther
    Mar 17, 2005
  4. kalyan chakravarthy

    how to assign custom server control properties at run time?

    kalyan chakravarthy, Oct 1, 2003, in forum: ASP .Net Building Controls
    Replies:
    0
    Views:
    134
    kalyan chakravarthy
    Oct 1, 2003
  5. Peter Morris [Air Software Ltd]

    WebControl with non-WebControl property

    Peter Morris [Air Software Ltd], Dec 7, 2004, in forum: ASP .Net Web Controls
    Replies:
    1
    Views:
    126
    Peter Morris [Air Software Ltd]
    Dec 7, 2004
Loading...

Share This Page