Thread: Getting opened file paths

  1. #1
    Android geek@02's Avatar
    Join Date
    Mar 2004
    Location
    Kurunegala Colony, Sri Lanka, Sri Lanka
    Posts
    470

    Getting opened file paths

    hi,
    i need 2 get the paths of all the opened files on a givan moment. 4 example, if there's a file called "ayesha.doc" is opened on the desktop, i need 2 get the file path of that file. what's the standered way 2 do this in C++ please?

    thanx a lot.
    GameJolt: https://gamejolt.com/@KasunL
    Game Development Youtube:
    https://is.gd/XyhYoP
    Amateur IT Blog: http://everything-geeky.blogspot.com/



    (and, sorry for my amateur English)

  2. #2
    Registered User
    Join Date
    Nov 2001
    Posts
    1,348
    Are you talking about arbitrary files or files your process owns?

    Kuphryn

  3. #3
    Android geek@02's Avatar
    Join Date
    Mar 2004
    Location
    Kurunegala Colony, Sri Lanka, Sri Lanka
    Posts
    470
    thanx for replying.

    not the files my process owns, but the files opened with other processes. (i need to get their paths, and get handles to the windows own by them)
    GameJolt: https://gamejolt.com/@KasunL
    Game Development Youtube:
    https://is.gd/XyhYoP
    Amateur IT Blog: http://everything-geeky.blogspot.com/



    (and, sorry for my amateur English)

  4. #4
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,660
    http://www.sysinternals.com/Processe...Utilities.html
    Handle v3.1
    This handy command-line utility will show you what files are open by which processes, and much more.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  5. #5
    Android geek@02's Avatar
    Join Date
    Mar 2004
    Location
    Kurunegala Colony, Sri Lanka, Sri Lanka
    Posts
    470
    thanx, but that's just a peice of software. it displays all the processes and the files they have opened, but there's no sourcecode to see how it's done. i need to write my own code for my own program. so... i still need help please.
    Last edited by geek@02; 09-18-2005 at 04:13 AM.
    GameJolt: https://gamejolt.com/@KasunL
    Game Development Youtube:
    https://is.gd/XyhYoP
    Amateur IT Blog: http://everything-geeky.blogspot.com/



    (and, sorry for my amateur English)

  6. #6
    Registered User
    Join Date
    Nov 2001
    Posts
    1,348
    Check out MSDN.

    http://msdn.microsoft.com/library/de..._reference.asp

    Check out my website for software development links.

    http://www.dslextreme.com/users/kuphryn/links.html

    Kuphryn

  7. #7

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. To find the memory leaks without using any tools
    By asadullah in forum C Programming
    Replies: 2
    Last Post: 05-12-2008, 07:54 AM
  2. help with text input
    By Alphawaves in forum C Programming
    Replies: 8
    Last Post: 04-08-2007, 04:54 PM
  3. Post...
    By maxorator in forum C++ Programming
    Replies: 12
    Last Post: 10-11-2005, 08:39 AM
  4. Unknown Memory Leak in Init() Function
    By CodeHacker in forum Windows Programming
    Replies: 3
    Last Post: 07-09-2004, 09:54 AM
  5. Rewriting an opened file.
    By Daghdha in forum C Programming
    Replies: 5
    Last Post: 06-13-2002, 01:55 AM