473,395 Members | 1,629 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

ExpandableObjectConverter on a struct

Ok here is the problem. I have a struct property on an object that I
want to edit with the property grid. One of the properties of the
properties of the struct is supposed to be read only to the user.

The inital problem is that when you use the ExpandableObjectConverter
as the type converter the values reset themselfs back to their orginal
values. Most likely because the Propertygrid has a copy of the value
and not the value itself.

So I found by overloading the
CreateInstance
GetCreateInstanceSupported
Methods of the typeconverter I could get the value in.
However now all my Properties are Writable (even the ones without a
"set" implemented)

What is the right way to do this?

Jul 21 '05 #1
0 1297

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Pol Bawin | last post by:
Hi, I have a objectA with a property that return an object B (accessor GET only) I have defined an ExpandableObjectConverter on the type B and overrided CanConvertTo, CanConvertFrom, ... The...
0
by: Vladimir.Sakharuk | last post by:
I have created ExpandableObjectConverter in C#. for use in System.Windows.Forms.PropertyGrid. The property grid shows the DiffItem is a object that holds member TheItem. without expanding...
0
by: Adriano Coser | last post by:
Hello. I'm facing the exact problem described here:...
0
by: Adriano Coser | last post by:
Hello. I have an ExpandableObjectConverter subclass that I associate to the 'Converter' of a custom property descriptor. After I changed my .net code to the new syntax (VC 2005), the...
0
by: tsteinke | last post by:
Ok here is the problem. I have a struct property on an object that I want to edit with the property grid. One of the properties of the properties of the struct is supposed to be read only to the...
0
by: Marcus Müller | last post by:
Hi, I'm using classes with the ExpandableObjectConverter attibute in a UserControl for properties. This works fine for some classes, and properties of these classes can be edited during design...
0
by: Nebelung | last post by:
Hi! I've written a custom ExpandableObjectConverter in which I have overridden GetPropertiesSupported and GetProperties (and some more). By setting breakpoints in all methods I have found out...
2
by: =?Utf-8?B?TWFyayBDb2xsYXJk?= | last post by:
I've created a usercontrol with a Person property. The Person property returns a Person object. I've also created a PersonConverter class which inherits the ExpandableObjectConverter so the Person...
0
by: Rohan | last post by:
Hello, i am doing a custom class for my property for a property gird using ExpandableObjectConverter. I have a class (CustomFontClass) that uses a Converter which inherits the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.