473,404 Members | 2,187 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,404 software developers and data experts.

Sort properties inside a category

Hi All,

I have defined some properties on a object with a category Attribute
How can I use a custom sort inside a category ?

See below

By default :

General information <- Category
Adress
Name
ID
Private Information <- Category
Email
Phone number

I would like :

General information <- Category
ID
Name
Adress
Private Information <- Category
Phone number
Email

Thanks

Nov 15 '05 #1
5 1883

Hi Polo,

Based on my understanding, your 3 property Adress, Name, ID are all
added the attribute Category("General"), so they will appear in the General
category in property grid. So is with Phone number, Email which are
placed in Private category.
But I do not know why you said they original appear as :
Adress
Name
ID

Because so far as I think, .Net will order all the property in the same
category alphabetically. Like this:
Adress
ID
Name

Beside this:
For your requirement, do you want the order of all the property in the same
category determine by yourself?

If I misunderstand you, please feel free to tell me.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

Nov 15 '05 #2
In fact, I woul like to have a custom sort in the category

""Jeffrey Tan[MSFT]"" <v-*****@online.microsoft.com> a écrit dans le message
de news:07*************@cpmsftngxa06.phx.gbl...

Hi Polo,

Based on my understanding, your 3 property Adress, Name, ID are all
added the attribute Category("General"), so they will appear in the General category in property grid. So is with Phone number, Email which are
placed in Private category.
But I do not know why you said they original appear as :
Adress
Name
ID

Because so far as I think, .Net will order all the property in the same
category alphabetically. Like this:
Adress
ID
Name

Beside this:
For your requirement, do you want the order of all the property in the same category determine by yourself?

If I misunderstand you, please feel free to tell me.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

Nov 15 '05 #3
I don't think that is possible...

vJ

"Polo" <pb@rtech.be> wrote in message
news:3f**********************@reader1.news.skynet. be...
In fact, I woul like to have a custom sort in the category

""Jeffrey Tan[MSFT]"" <v-*****@online.microsoft.com> a écrit dans le message de news:07*************@cpmsftngxa06.phx.gbl...

Hi Polo,

Based on my understanding, your 3 property Adress, Name, ID are all added the attribute Category("General"), so they will appear in the

General
category in property grid. So is with Phone number, Email which are placed in Private category.
But I do not know why you said they original appear as :
Adress
Name
ID

Because so far as I think, .Net will order all the property in the same
category alphabetically. Like this:
Adress
ID
Name

Beside this:
For your requirement, do you want the order of all the property in the

same
category determine by yourself?

If I misunderstand you, please feel free to tell me.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.


Nov 15 '05 #4

Hi Polo,

I think may be you can get this done through implement
ICustomTypeDescriptor interface for your component. For its GetProperties()
method, return your wanted property order. And there is a sort method of
PropertyDescriptorCollection, you may adjust the property order through
this method.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

Nov 15 '05 #5

Oh Polo,

After some research, I found that this can not be done in VS.net property
grid.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

Nov 15 '05 #6

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

Similar topics

0
by: tsirman | last post by:
hello i have the above code and i can't sort my data in the second column. if someone did not understood i want to say that i have splitted my data in two columns so now i want these data to be...
2
by: Rick Austin | last post by:
I recently had to perform a reinstalltion of Windows XP (my registry seems to have become corrupt). After this completed I had to reinstall all applications since most use the registry for settings,...
1
by: 2G | last post by:
Hi, I have a usercontrol with a custom propertie but in the designer, the properties doesn't expand it's properties so I can't change them. I've search google on this and came across things like...
0
by: Emil Georgiev | last post by:
Hell I have a Web Custom Control project in ASP.NET. I'm using a subclassing technique to add functionality in HyperLink web server control. I want to create a property "BrowserWindow" of my...
4
by: tfs | last post by:
Is there a way in asp.net to get the file properties such as: author, subject,title and category. Apparently, fileinfo doesn't have that. I need to get the these as we are going to use them for...
4
by: Joe | last post by:
Hello, I have a datagrid in an nested html table (one table inside of another table) and have set the allowsSorting property to true. I've created in the code-behind a method (Sub - I'm using...
0
by: =?iso-8859-1?q?Stefan_Sch=F6b?= | last post by:
Hi I've got here a simple PropertyGrid on my Form. And there is an Array with n-Objects of simple Class with n Attributes. I used the Code of the following Article to localize all the...
10
by: Brion | last post by:
Is it possible to sort outer and inner strings at once? The sorted output should look like the following: <category>Bars</category> <name>Alpha Bar</name> <name>Beta Bar</name> ...
0
by: creejohn | last post by:
Hi all-- I'm really stumped here. I have a (c# 2.0) calendar control that loads a menu for each day inside the cell corresponding to that day in the dayrender event. That is all working great. I...
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
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:
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
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
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
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,...
0
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...

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.