About UITypeEditor

1. When I override EditValue method as follows:

        [PermissionSet(SecurityAction.LinkDemand, Name = "FullTrust")]
        public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value)
        {
            MessageBox.Show(value.ToString());

            return value;
        }


        [PermissionSet(SecurityAction.LinkDemand, Name = "FullTrust")]
        public override UITypeEditorEditStyle GetEditStyle(ITypeDescriptorContext context)
        {
            if (context != null && context.Instance != null)
            {
                return UITypeEditorEditStyle.None;
            }
            return base.GetEditStyle(context);
        }

And I input something in the property textbox,it doesn't run the MessageBox,why

2.which base type should I inherit if I need display all workflows's parameters in listbox like default DependencyProperty's behavior Because I need override EditValue method to do something else.

thanks

 




Answer this question

About UITypeEditor

  • Scav

    You have to create a custom UITypeEditor there isn't one that you can derive from to do what you want. There is a sample here that should help you get started.

  • About UITypeEditor