UserControl and property

Discussion in 'ASP .Net Building Controls' started by Brian Bugge, Dec 26, 2003.

  1. Brian Bugge

    Brian Bugge Guest

    Is it possible to display properties of my usercontrol in the propertygrid
    in vs.net

    eg.

    [System.ComponentModel.Browsable(true),System.ComponentModel.EditorBrowsable
    (EditorBrowsableState.Always),DesignerSerializationVisibility(DesignerSerial
    izationVisibility.Visible)]
    public string Text{

    get{

    return this.mytextvar;

    }

    set{

    this.mytextvar=value;

    }

    }

    The above does not work, anyone who knows why ?

    The only properties in the propertygrid is: EnableViewStae, Visible,
    (Databindings), ID

    (It is not a custom control, but a System.Web.UI.UserControl)

    Brian Bugge - Denmark
     
    Brian Bugge, Dec 26, 2003
    #1
    1. Advertising

  2. Brian Bugge

    Teemu Keiski Guest

    Hi,

    this is limitation with user controls and is not supported in current VS.NET
    versions. New Web Matrix and becoming VS.NET should bring design-time
    support for user controls (at web form) and probably also the way to view
    properties in Property Browser.

    --
    Teemu Keiski
    MCP, Microsoft MVP (ASP.NET), AspInsiders member
    ASP.NET Forum Moderator, AspAlliance Columnist

    "Brian Bugge" <> wrote in message
    news:bshtjf$1u12$...
    > Is it possible to display properties of my usercontrol in the propertygrid
    > in vs.net
    >
    > eg.
    >
    >

    [System.ComponentModel.Browsable(true),System.ComponentModel.EditorBrowsable
    >

    (EditorBrowsableState.Always),DesignerSerializationVisibility(DesignerSerial
    > izationVisibility.Visible)]
    > public string Text{
    >
    > get{
    >
    > return this.mytextvar;
    >
    > }
    >
    > set{
    >
    > this.mytextvar=value;
    >
    > }
    >
    > }
    >
    > The above does not work, anyone who knows why ?
    >
    > The only properties in the propertygrid is: EnableViewStae, Visible,
    > (Databindings), ID
    >
    > (It is not a custom control, but a System.Web.UI.UserControl)
    >
    > Brian Bugge - Denmark
    >
    >
     
    Teemu Keiski, Dec 30, 2003
    #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. huobazi
    Replies:
    1
    Views:
    733
    David Waz...
    Jul 3, 2003
  2. Rajesh Tiwari

    Can we use a usercontrol inside a usercontrol

    Rajesh Tiwari, Aug 12, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    438
    Rajesh Tiwari
    Aug 12, 2003
  3. nail
    Replies:
    0
    Views:
    1,568
  4. Fabiano
    Replies:
    2
    Views:
    640
    =?Utf-8?B?c3Jpbmk=?=
    Jun 3, 2005
  5. ThunderMusic
    Replies:
    4
    Views:
    431
    ThunderMusic
    Dec 21, 2005
Loading...

Share This Page