server control serialization problem with UiTypeEditor

Discussion in 'ASP .Net Building Controls' started by crazyhorse, May 23, 2005.

  1. crazyhorse

    crazyhorse Guest

    Have a expandable property that is passed to a uitypeeditor which the
    property does not get serialized. Value from uitypeeditor updates in
    the designer window but not in run mode. Have tried both
    DesignerSerializationVisibility.Content and
    DesignerSerializationVisibility.Visible with no success. Could it be
    something in my Uitypeeditor or menudata class that can cause the
    serialization class. Can post more code if needed. Please give me
    some tips of what to look for.

    //property
    [
    Editor(typeof(TextEditor),typeof(UITypeEditor))
    ]
    [DefaultValue("Enter"), Category("Data"),
    PersistenceMode(PersistenceMode.InnerProperty),
    NotifyParentProperty(true),RefreshProperties(RefreshProperties.All),DesignerSerializationVisibility(DesignerSerializationVisibility.Content)
    ]
    public menudata MenuData3
    {
    get{return _mdata;}
    set{_mdata = value;}
    }


    private menudata _mdata = new menudata();



    ----------------------------------------------------------------
    menudata.cs
    ----------------------------------------------------------------
    using System;
    using System.Web.UI;
    using System.Web.UI.WebControls;
    using System.ComponentModel;
    using System.Xml;
    using System.Text;
    using System.ComponentModel.Design;

    namespace MenuLib
    {
    [Serializable]
    [TypeConverter(typeof(_menudataoverride))]
    public class menudata: ExpandableObjectConverter
    {
    public menudata()
    {
    _menuxml="TEST";
    }

    string _menuxml;


    // Created by VS.NET
    [Bindable(false),
    NotifyParentProperty(true),
    RefreshProperties(RefreshProperties.Repaint)
    ]
    public string menuxml
    {
    get { return _menuxml; }
    set{ _menuxml = value; }
    }

    }
    }
     
    crazyhorse, May 23, 2005
    #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. Ken Dopierala Jr.
    Replies:
    0
    Views:
    515
    Ken Dopierala Jr.
    May 13, 2005
  2. WALDO

    Override UITypeEditor on class

    WALDO, Oct 19, 2004, in forum: ASP .Net Building Controls
    Replies:
    1
    Views:
    317
    WALDO
    Oct 20, 2004
  3. Ken Dopierala Jr.

    How do I have a UITypeEditor tell the Designer that the component has changed?

    Ken Dopierala Jr., May 13, 2005, in forum: ASP .Net Building Controls
    Replies:
    2
    Views:
    229
    Ken Dopierala Jr.
    May 13, 2005
  4. Ahmed Hashish

    Custom UITypeEditor

    Ahmed Hashish, Jul 21, 2005, in forum: ASP .Net Building Controls
    Replies:
    0
    Views:
    131
    Ahmed Hashish
    Jul 21, 2005
  5. Diego Javier Martínez

    Using UITypeEditor type in webcontrols design

    Diego Javier Martínez, Sep 6, 2006, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    230
    Diego Javier Martínez
    Sep 6, 2006
Loading...

Share This Page