473,698 Members | 2,490 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

PropertyGrid String List TypeConverter/Desciptor

Hi,

I would like to create a workable ExpandableObjec tConverter for a String
Collection (class inheriting from CollectionBase for example and only
accepting/returning Strings via Add/Remove/Item/DefaultProprty) and a fitting
Descriptor (implementing ICustomTypeDesc riptor)... now i created it and it
somewhat works.. my big problem is that i the String classs does not have a
default constructor and so the "Add" item in the collection pop up does not
work.

So i created a simple class with just a single string based data field and
coresponding property... created a typeconverter for it and it worked
somewhat... the problem is my TypeConverter's ConvertFrom method converts the
string into my StringItem class instance which it then returns... but the
Collection Item is never replaced/updated... so the Collection/List value
never changes...

How do i make it work?

In total i would like to have a Path List Object (using a FolderName
EditorAttribute ) that i can simpley add to a property grid where i see all
the paths and can change each path directly (typing in the list) or via "..."
select button.

How is something like this possible?

Thanks
Dec 6 '05 #1
0 1282

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

Similar topics

3
6044
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 from a database and manipulate the TypeConverters dynamically. The property grid then displays the property with a drop down list. It does work when I open the application for the first time. If, however, I open the form and then open a second...
1
24665
by: Daniel | last post by:
How do I use a combobox in a propertygrid without using enum ? Any suggestions?
0
1038
by: Frank Rizzo | last post by:
Hello, I have the property grid control in my WinForm app. I have a property where I implemented a simple drop-down editor via the TypeConverter. I was wondering whether it is possible to add items to the dropdown after the application has initially populated it? For instance, consider the code below. In it, the ColorThemeManager exposes in the dropdown the list of files with the .ColorTheme extention. At some point, the another...
0
1531
by: movieknight | last post by:
Hi, I have a class which I am feeding to the propertygrid, and I am exposing a Mesh object from my class for the propertygrid to display. I want the propertygrid to show the values (when you expand the property) and allow those values to be edited. My code is below. The grid is showing the values but they are read-only, although the other properties for the rest of my class are editable. Public Class MeshConverter
5
3015
by: Lee | last post by:
Hi, Using the propertygrid, is it possible to have a user selectable 'unit of measure' for a field. For example, I am looking at using a propertygrid for defining inputs into a calculation. Some of the inputs can be either monetary or percantage. The ideal scenario is where the user enters the value and immediately to the right of the value field is a drop down, defaulted to %,which allows a currency to be selected.
4
3302
by: Tugrul HELVACI | last post by:
Changing DisplayNames of my properties using PropertyGrid component, how ?? I'm using Delphi 2006 and I have a class defination like this: TPerson = class fPersonName : String; fPersonSurName : String; fPersonAge : Integer; published property PersonName : String read fPersonName write fPersonName;
4
35963
by: Steve | last post by:
I am using a property grid to display a classes properties, all is OK for single value properties but i need to display a list of strings for the user to select from and update the property value based on the selection. A Drop down list in the property grid would be ideal. For instance - like the StartPosition property of a form in the IDE. I think this would be a simple and often used procedure but i have not been able to locate an...
4
18820
by: phcmi | last post by:
I have a PropertyGrid question. My task is to replace a legacy dialog box presentation with a modern one. The dialog itself allows the user to set configuration settings in our application, so it seems to me that a PropertyGrid is a perfect modern replacement. I won't bore you with the details with all the controls on the dialog since I'm only concerned with one issue. The legacy dialog contains a drop down list control that is...
3
5190
by: Redivivus | last post by:
Hi Ho to use dropdown in propertygrid with values from database? Lets say i have table ITEMS and columns ID, NAME Now i want to select id, name from items and display those values in dropdown of my propertygrid
0
8612
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9171
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9032
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
7743
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6532
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4373
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4625
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2342
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2008
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.