473,386 Members | 1,819 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,386 software developers and data experts.

Prop Grids TypeConverters and IDesigners Oh My!

I use a PropertyGrid in my UI. I had a property of type image, and the prop
grid popped up an open file dialog where the user could select an image,
then display a tiny thumbnail of it, along with the image type.

I've had to change the type of this property to a new class of my own, which
will still contain an image, but I need to handle opening the image myself.
So now, in the prop grid, I just get a grayed out string with my classes
name in it.

I would really like to make the property grid behave like it did when the
property was of type Image. I've been looking at TypeConverter, and such in
MSDN, and I'm very confused.

Basically, I want the user to click the ellipsis button, and see the open
file dialog, select a file of a type supported by the Image class, but take
in the filename from the dialog, do my own thing with it, and then show the
thumbnail with the image type in the property grid just like any other
property of type Image.

I know is that I've got to make a type converter, but I've almost no idea
what to put in the class, or how this whole thing will work, or even if it's
possible!

Any ideas WELL appreciated,
Eric
Nov 15 '05 #1
0 922

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

Similar topics

3
by: Dave Girvitz | last post by:
I have a PropertyGrid (Windows Forms App) based component that uses TypeConverters to generate ranges of acceptable values for properties. The idea was that I could download the key/value pairs...
2
by: orekinbck | last post by:
Hi There Using C# forms, I have a main screen that contains 2 data grids. * The data grids are connected to ArrayLists (each grid has its own ArrayList) * The data grids are intended for...
1
by: James G. Beldock | last post by:
I must be missing something simple: I've got several grids on a single page. Those grids can have a variable numbers of lines. But if they expand or contract, I can't figure out how to move the...
0
by: IGotYourDotNet | last post by:
I have a page and I need to put multiple grids on it, (10 to be exact). The issue i'm having is sometime some grids have 3 records and sometimes they can have 20 records and what happens is that the...
0
by: ljlevend | last post by:
I need to create TypeConverters for the floating type drawing structures (i.e., PointF, SizeF and RectangleF) that behave exactly as their integer couterparts (e.g., System.Drawing.PointConverter)....
0
by: David Veeneman | last post by:
This post is for the Google crawler-- no response in required. Can a containment hierarchy made up of two collections derived from BindingList<T> be data-bound to master-detail dataGridView...
0
by: herpers | last post by:
Hi, I'm writing a control with a lot of properties, that are not directly supported by the propertygrid. I can work around this by writing typeconverters, that do the job for me, but I think for...
3
by: =?Utf-8?B?R3JlZyBDbGFyaw==?= | last post by:
I have an object which I present to the user through a propertyGrid. With many of the properties (many of which are objects themselves) I have implemented my own TypeConverters; many of these...
1
by: Uriah Piddle | last post by:
Hi Gang, I can't make my ValidationSummary render in red. I set the ForeColor prop to red inline and it renders black. If I set the Font-underline prop to 'True', it renders with a RED underline...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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,...

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.