Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to list the recent documents using API?
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00636738
Message ID:
00636783
Views:
16
>Desenvolvedor de sistema em VFP
>how to list the recent documents using API????

As Daniel mentioned the WScript.Shell object can get you the folder. You will, however, need to resolve the shortcut links in the folder to determine the documents and their location. Here's a simply method to do this.
oShell = CREATEOBJECT("WScript.Shell")
* Get the location of the recent folder
lcpath = oShell.SpecialFolders("Recent")
* Load an array with the shortcut link file names
lnlast = ADIR(a_dir, lcpath + "\*.LNK")
FOR lni = 1 TO lnlast
  oShortcut = oShell.CreateShortCut(lcpath + "\" + a_dir[lni, 1])
  ? oShortcut.TargetPath
NEXT
George

Ubi caritas et amor, deus ibi est
Previous
Reply
Map
View

Click here to load this message in the networking platform