'©2007 by ytwinky, MD wrx in FB0.16b #include once "windows.bi" #include once "win/shlobj.bi" Function GetSpecialfolder(CSIDL As Integer) As String Dim As LPITEMIDLIST pidlStart Dim Pfad As ZString * MAX_PATH If SHGetSpecialfolderLocation(0, CSIDL, @pidlStart)=NOERROR Then 'Get the special folder SHGetPathFromIDList(pidlStart, Pfad) 'Get the path from the IDList Else Pfad="" End If Return Pfad End Function Dim As String s, s_Out 'From AllAPI.Exe: 'Const CSIDL_DESKTOP=&H0 'Windows desktop-virtual folder at the root of the name space 'Const CSIDL_PROGRAMS=&H2 'File system directory that contains the user's program groups (which are also file system directories). 'Const CSIDL_CONTROLS=&H3 'Control Panel-virtual folder containing icons for the control panel applications 'Const CSIDL_PRINTERS=&H4 'Printers folder-virtual folder containing installed printers 'Const CSIDL_PERSONAL=&H5 'File system directory that serves as a common respository for documents 'Const CSIDL_FAVORITES=&H6 'File system directory that corresponds to the user's favourites 'Const CSIDL_STARTUP=&H7 'File system directory that corresponds to the user's Startup program group 'Const CSIDL_RECENT=&H8 'File system directory that contains the user's most recently used documents 'Const CSIDL_SENDTO=&H9 'File system directory that contains Send To menu items 'Const CSIDL_BITBUCKET=&HA 'I think this may be the (virtual) trash folder.. 'Const CSIDL_STARTMENU=&HB 'File system directory containing Start menu items 'Const CSIDL_DESKTOPDIRECTORY=&H10 'File system directory used to physically store file objects on the desktop (not to be confused with the desktop folder itself) 'Const CSIDL_DRIVES=&H11 'My Computer-virtual folder containing everything on the local computer: storage devices, printers, and Control Panel. The folder may also contain mapped network drives 'Const CSIDL_NETWORK=&H12 'Network Neighborhood-virtual folder representing the top level of the network hierarchy 'Const CSIDL_NETHOOD=&H13 'File system directory containing objects that appear in the network neighborhood 'Const CSIDL_FONTS=&H14 'Virtual folder containing fonts 'Const CSIDL_TEMPLATES=&H15 'File system directory that serves as a common repository for document templates s="01 Desktop folder: " &GetSpecialfolder(CSIDL_DESKTOP) &!"\n" s+="02 Programs folder: " &GetSpecialfolder(CSIDL_PROGRAMS) &!"\n" s+="03 Virtual control panel folder: " &GetSpecialfolder(CSIDL_CONTROLS) &!"\n" s+="04 Virtual printers folder: " &GetSpecialfolder(CSIDL_PRINTERS) &!"\n" s+="05 Personal folder: " &GetSpecialfolder(CSIDL_PERSONAL) &!"\n" s+="06 Favorites folder: " &GetSpecialfolder(CSIDL_FAVORITES) &!"\n" s+="07 Users startup folder: " &GetSpecialfolder(CSIDL_STARTUP) &!"\n" s+="08 Recent documents folder: " &GetSpecialfolder(CSIDL_RECENT) &!"\n" s+="09 Sendto folder: " &GetSpecialfolder(CSIDL_SENDTO) &!"\n" s+="10 Virtual BitBucket folder: " &GetSpecialfolder(CSIDL_BITBUCKET) &!"\n" s+="11 Startmenu folder: " &GetSpecialfolder(CSIDL_STARTMENU) &!"\n" s+="12 Desktop folder: " &GetSpecialfolder(CSIDL_DESKTOPDIRECTORY) &!"\n" s+="13 Virtual drives folder: " &GetSpecialfolder(CSIDL_DRIVES) &!"\n" s+="14 Virtual Network folder: " &GetSpecialfolder(CSIDL_NETWORK) &!"\n" s+="15 Nethood folder: " &GetSpecialfolder(CSIDL_NETHOOD) &!"\n" s+="16 Virtual fonts folder: " &GetSpecialfolder(CSIDL_FONTS) &!"\n" s+="17 Templates folder: " &GetSpecialfolder(CSIDL_TEMPLATES) &!"\n" s+="If there are any pathes missing, I beg your pardon :D" CharToOem(s, s) 'OemToChar(s, s) Print s GetKey