Loosing property values; and design time rendering

Discussion in 'ASP .Net Web Controls' started by Mark Norgate, Aug 24, 2003.

  1. Mark Norgate

    Mark Norgate Guest

    Hi

    I'm having a couple of problems with a control I'm developing.

    Firstly, I have a custom property called InnerHtml. Whenever I populate this
    in the properties window, the value is immediately deleted when the
    application in run. Why would this be? Here's the code for the property
    accessors:

    public string InnerHtml {
    get {
    object o = ViewState["InnerHtml"];
    if( o!=null )
    return o.ToString();
    else
    return "";
    }
    set {
    ViewState["InnerHtml"] = value;
    }
    }

    Secondly, my control designer does not seem to render at all in the
    designer. I'm using a very simple GetDesignTimeHtml() implementation:

    public override string GetDesignTimeHtml() {
    return CreatePlaceHolderDesignTimeHtml( "XhtmlControl" );
    }

    ....and I think I'm connecting it properly in the control:

    Designer("Refresh.WebControls.XhtmlControlDesigner", "XhtmlControl")

    Why is nothing appearing? All I see are the resizing handles all bunched
    together.

    Thanks, Mark
     
    Mark Norgate, Aug 24, 2003
    #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. Ziyad Makki
    Replies:
    0
    Views:
    320
    Ziyad Makki
    Aug 2, 2004
  2. MBO
    Replies:
    0
    Views:
    302
  3. Ryan Taylor

    using the Items property in the design time property window

    Ryan Taylor, Feb 8, 2005, in forum: ASP .Net Building Controls
    Replies:
    4
    Views:
    539
    Paul Louth
    Feb 18, 2005
  4. MBO

    Property is loosing value

    MBO, Jul 28, 2005, in forum: ASP .Net Building Controls
    Replies:
    0
    Views:
    134
  5. MBO

    Property is loosing value

    MBO, Jul 28, 2005, in forum: ASP .Net Web Controls
    Replies:
    3
    Views:
    124
    Teemu Keiski
    Jul 29, 2005
Loading...

Share This Page