CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7

Thread: Help Needed

  1. #1
    Join Date
    Aug 2006
    Posts
    5

    Exclamation Help Needed

    I am looking for 2 codes that I am having great difficulty finding and hoping that you guys would be able to help

    the first code that I need is a piece of code that sorts by date, you enter a date and time and it will sort the files

    the second piece of code that is needed is code that generates a tree view of the files

    thanks for the help
    -TheDocta

    p.s. please dont hate me if I typed something incorrectly I am new here and trying to get used to it thanks

  2. #2
    Join Date
    Aug 2006
    Posts
    69

    Re: Help Needed

    With respect, it sounds as though you want someone else to do all your work for you. What have you tried? What specific things are you having problems with? Can you post code examples of what you have (in [code] [/code] tags, please)?

  3. #3
    Join Date
    Aug 2006
    Posts
    5

    Re: Help Needed

    Quote Originally Posted by thelinuxduck
    With respect, it sounds as though you want someone else to do all your work for you. What have you tried? What specific things are you having problems with? Can you post code examples of what you have (in tags, please)?
    Im not looking for someone to do the codeing for me, it just seems like it is a common code that people would most likely have so I figured that someone would know where to get it on the internet as a lot of code can be found there, I dont want someone to do the work for me I just want to know if it is already out there so i can save myself the time

  4. #4
    Join Date
    Aug 2006
    Posts
    69

    Re: Help Needed

    Quote Originally Posted by TheDocta
    I am looking for 2 codes
    What do you mean by 'codes'? Libraries? User Controls? Classes? Methods?

    the first code that I need is a piece of code that sorts by date, you enter a date and time and it will sort the files
    How do "you enter a date and time"? Via a popup dialog? In the code itself? Telepathy?

    Sort what files? How are they loaded/stored? Sorted by creation date? Access date? Date of some data from within the file?

    the second piece of code that is needed is code that generates a tree view of the files
    I seriously doubt you spent any time searching. I googled for 'tree view "c sharp" and pulled up a great number of hits with very relevant information.

    Again, I ask, where is your code that you're having problems with? Show where you're getting stuck. What are the errors? You've come in here and asked a question with almost no information or details, let alone things you've tried.

    I mean no disrespect to you, but if you want someone to help you, you need to show that you're trying. If it appears that you're not even trying to solve the problem, you can expect a reply like mine.

  5. #5
    Join Date
    Jun 2006
    Location
    Minnesota
    Posts
    257

    Re: Help Needed

    DirectoryInfo object info

    FileInfo object info

    Use this code to get the directory into FileInfo objects.
    Code:
    DirectoryInfo di = new DirectoryInfo(path);
    FileInfo[] fi = di.GetFiles();
    Read from the links below to get how to sort stuff. You can find this information easily enough by going to google and searching. Here's the google link:

    Google search

    FileInfo Sort 1

    FileInfo Sort 2

  6. #6
    Join Date
    Oct 2005
    Location
    Islamabad, Pakistan
    Posts
    1,277

    Re: Help Needed

    the second piece of code that is needed is code that generates a tree view of the files
    Sample
    Attached Files Attached Files

  7. #7
    Join Date
    Aug 2006
    Posts
    5

    Re: Help Needed

    thank you gentleman,

    with your help i think I have found what i need to complete the task at hand

    i found how google was searched interesting because my search tries were much more basic but i now see that your way was a lot better

    Thank you for all the help
    -TheDocta

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured