Click here to Skip to main content
15,895,084 members
Home / Discussions / C#
   

C#

 
AnswerRe: Disk Space Pin
prrusa10-Mar-06 16:04
prrusa10-Mar-06 16:04 
GeneralRe: Disk Space Pin
Sean8910-Mar-06 16:51
Sean8910-Mar-06 16:51 
QuestionOne line appears and multilines appear Pin
ahchoo10-Mar-06 10:33
ahchoo10-Mar-06 10:33 
Questionround robin and fifo algorithm Pin
eey5610-Mar-06 9:17
eey5610-Mar-06 9:17 
AnswerRe: round robin and fifo algorithm Pin
Office Lineman10-Mar-06 9:32
Office Lineman10-Mar-06 9:32 
GeneralRe: round robin and fifo algorithm Pin
eey5610-Mar-06 11:09
eey5610-Mar-06 11:09 
Questionplease help: using wininet.dll to get Internet Access form Application Pin
gaorellana10-Mar-06 8:55
gaorellana10-Mar-06 8:55 
QuestionSort / Find on BindingList Pin
Chris Losinger10-Mar-06 8:47
professionalChris Losinger10-Mar-06 8:47 
i've inherited a projects that uses a BindingList to hold DB records. i want to be able to sort the items in the BindingList.

the code for the BindingList-derived class has FindCore, SearchCore and all the things I assume are required to do the sorting. but, i simply cannot figure out how to call it.

ex. the FindCore member looks like this:
protected override int FindCore(PropertyDescriptor property, object key)
{

    // Specify search columns
    if (property == null) return -1;

    // Get list to search
    List<T> items = this.Items as List<T>;

    // Traverse list for value
    foreach (T item in items)
    {

        // Test column search value
        string value = (string)property.GetValue(item);

        // If value is the search value, return the
        // index of the data item
        if ((string)key == value) return IndexOf(item);
    }
    return -1;
}


my problem is... i don't know enough C# to know how to create that PropertyDescriptor object in order to tell the function to search the contained items on a given property.

i've found a dozen articles on the web that tell me how to write the FindCore function, but none that show how to call it.


Cleek | Image Toolkits | Thumbnail maker

AnswerRe: Sort / Find on BindingList Pin
Nicholas Butler11-Mar-06 1:49
sitebuilderNicholas Butler11-Mar-06 1:49 
GeneralRe: Sort / Find on BindingList Pin
Chris Losinger13-Mar-06 4:21
professionalChris Losinger13-Mar-06 4:21 
AnswerRe: Sort / Find on BindingList Pin
Nicholas Butler13-Mar-06 4:59
sitebuilderNicholas Butler13-Mar-06 4:59 
GeneralRe: Sort / Find on BindingList Pin
Chris Losinger13-Mar-06 7:26
professionalChris Losinger13-Mar-06 7:26 
QuestionBuilding DotnetNuke module Using C# 2.0 Pin
Chandana Subasinghe10-Mar-06 7:37
Chandana Subasinghe10-Mar-06 7:37 
AnswerRe: Building DotnetNuke module Using C# 2.0 Pin
Colin Angus Mackay10-Mar-06 12:51
Colin Angus Mackay10-Mar-06 12:51 
QuestionFileInfo.Exists returns False even if the file exists Pin
chopinrlz10-Mar-06 6:23
chopinrlz10-Mar-06 6:23 
AnswerRe: FileInfo.Exists returns False even if the file exists Pin
Dan Neely10-Mar-06 6:53
Dan Neely10-Mar-06 6:53 
AnswerRe: FileInfo.Exists returns False even if the file exists Pin
Stefan Troschuetz10-Mar-06 6:55
Stefan Troschuetz10-Mar-06 6:55 
AnswerRe: FileInfo.Exists returns False even if the file exists Pin
Guffa10-Mar-06 7:10
Guffa10-Mar-06 7:10 
AnswerRe: FileInfo.Exists returns False even if the file exists Pin
FocusedWolf10-Mar-06 8:42
FocusedWolf10-Mar-06 8:42 
QuestionImage with transparent background Pin
stu8310-Mar-06 5:33
stu8310-Mar-06 5:33 
QuestionImage with transparent background Pin
stu8310-Mar-06 5:24
stu8310-Mar-06 5:24 
QuestionControl visible changed event Pin
malharone10-Mar-06 4:28
malharone10-Mar-06 4:28 
AnswerRe: Control visible changed event Pin
Office Lineman10-Mar-06 6:10
Office Lineman10-Mar-06 6:10 
GeneralRe: Control visible changed event Pin
malharone10-Mar-06 7:36
malharone10-Mar-06 7:36 
GeneralRe: Control visible changed event Pin
Office Lineman10-Mar-06 7:56
Office Lineman10-Mar-06 7:56 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.