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

Listview and PropertyGrid on form

Hello,

I maybe asking too much in a single posting, but here it goes:

I building a windows form that mimic's the Outlook XP GUI. Its a three
pane form that will allow a user to view and edit records in a
database. A Treeview in the left pane, a Listview in the TopRight
Pane, and a PropertyGrid in the BottomRight; The Treeview will allow
the user to select an
"Entity" to view, the listview will display a list of instances of
that entity. The propertygrid will display the properties of the
instance(s) selected in the listview.

Barriers:

1) Can I add custom types to the listview control and having the
properties of the customtype appear as item\subitems ? I have seen
code were custom types inherit from ListViewItem, if this is the way
to add a custom type to the listview control, how doyou
populate\display the subitems? I am potentially displaying 20
different types(or collections of types) in the listview, do I need to
create a custom listviewitem for each of these types?

2) I can forsee having to create huge if\else or switch\case
statements to handle casting objects from one type to an other.
ListView Items to. I have read postings that suggestion creating an
interface that all custom types will implement, which then would
require you to cast only to the interface.
Are there c# examples of creating\implementing interfaces with GUI's,
I maybe asking too much .
I apologize if any of the questions are not clear or silly, this is my
first c# application, I have experience using c++Builder but I am new
to c#.

newbie
Nov 15 '05 #1
1 3423
> 1) Can I add custom types to the listview control and having the
properties of the customtype appear as item\subitems ? I have seen
code were custom types inherit from ListViewItem, if this is the way
to add a custom type to the listview control, how doyou
populate\display the subitems? I am potentially displaying 20
different types(or collections of types) in the listview, do I need to
create a custom listviewitem for each of these types?
I used the tab property of the ListviewItem to hold my custom types. I
am creating a couple of interfaces that the classes will need to
implement. This should minimize casting. I will cast any object to the
required interface to accomplish the necessary tasks.
ms******@yahoo.com (newbie) wrote in message news:<51**************************@posting.google. com>... Hello,

I maybe asking too much in a single posting, but here it goes:

I building a windows form that mimic's the Outlook XP GUI. Its a three
pane form that will allow a user to view and edit records in a
database. A Treeview in the left pane, a Listview in the TopRight
Pane, and a PropertyGrid in the BottomRight; The Treeview will allow
the user to select an
"Entity" to view, the listview will display a list of instances of
that entity. The propertygrid will display the properties of the
instance(s) selected in the listview.

Barriers:

1) Can I add custom types to the listview control and having the
properties of the customtype appear as item\subitems ? I have seen
code were custom types inherit from ListViewItem, if this is the way
to add a custom type to the listview control, how doyou
populate\display the subitems? I am potentially displaying 20
different types(or collections of types) in the listview, do I need to
create a custom listviewitem for each of these types?

2) I can forsee having to create huge if\else or switch\case
statements to handle casting objects from one type to an other.
ListView Items to. I have read postings that suggestion creating an
interface that all custom types will implement, which then would
require you to cast only to the interface.
Are there c# examples of creating\implementing interfaces with GUI's,
I maybe asking too much .
I apologize if any of the questions are not clear or silly, this is my
first c# application, I have experience using c++Builder but I am new
to c#.

newbie

Nov 15 '05 #2

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

Similar topics

6
by: Terry | last post by:
I have a very basic program, but for some reason I can't get it to behave properly. What I want is a basic form with a TabControl that fills the entire form. The tab control should have 4 tabs...
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...
3
by: Nicolas | last post by:
I want to display in my application a PropertyGrid showing only the "Appearance" of a control (ie. textBox) so the user can change it. Bare with me, I'm new in csharp. Where do I go from:...
3
by: Frank Rizzo | last post by:
I added a PropertyGrid control to my form and set its SelectedObject property to one of my objects which exposes a lot of properties of type System.Drawing.Color. The System.Drawing.Color display...
2
by: Rado | last post by:
Hello. How Can I make listview such as is a bottom of visual studio. Thank you.
4
by: Bernie Yaeger | last post by:
How can I set the browsableattributes of the control that has been selected (selectedobject) by the propertygrid? Here's what I'm after - I want to open a form with a propertygrid in it. The...
2
by: Lance | last post by:
I want to be able to reset a complex property in a PropertyGrid. I know that for properties that are ValueTypes you can include System.ComponentModel.DefaultValue in the declaration of the property....
6
by: Steve Teeples | last post by:
Can someone show me an example of how to place a "CheckedListBox" property within a PropertyGrid? -- ----------- Thanks, Steve
2
by: Marco Segurini | last post by:
Hi All, I have a form containing only a PropertyGrid that I use to modify an instance of the following class: class MyClass { Point _point = new Point();
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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.