Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/339.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# PropertyGrid中可为null的编辑器_C#_Datetime_Nullable - Fatal编程技术网

C# PropertyGrid中可为null的编辑器

C# PropertyGrid中可为null的编辑器,c#,datetime,nullable,C#,Datetime,Nullable,我已经为PropertyGrid中的动态加载属性创建了一个类inheritICustomTypeDescriptor。我需要在内部编辑DateTime。因此,如果类型为可空则未显示标准日历编辑器,但日期时间的编辑器工作正常,但我不能将编辑器字段保留为空(就像我想将值设置为空)。 笔记我没有使用类属性,所以我需要使用ICustomTypeDescriptor和PropertyDescriptor我使用的东西来解决这个问题 没人知道

我已经为PropertyGrid中的动态加载属性创建了一个类inherit
ICustomTypeDescriptor
。我需要在内部编辑
DateTime
。因此,如果类型为
可空
则未显示标准日历编辑器,但
日期时间
的编辑器工作正常,但我不能将编辑器字段保留为空(就像我想将值设置为
)。 笔记我没有使用类属性,所以我需要使用
ICustomTypeDescriptor
PropertyDescriptor
我使用的东西来解决这个问题

没人知道