Components | All | New | MacOS | Windows | Linux | iOS | ||||
Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old |
Folders.UserDesktop
Queries path to user's desktop folder.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
Folders | 4.3 | ✅ Yes | ✅ Yes | ❌ No | ❌ No | ✅ Yes |
MBS( "Folders.UserDesktop" )
Parameters
none
Result
Returns path or error.
Description
Queries path to user's desktop folder.This is a native path. You can use Path.NativePathToFileMakerPath if you need to use path in a script step.
For FileMaker Server it is possible to not have a desktop folder or to have it on a different location than normal user accounts.
Examples
Queries path:
MBS( "Folders.UserDesktop" )
Create folder on Desktop:
Set Variable [$folder; Value:MBS( "Folders.UserDesktop" )]
If [IsEmpty(Container Export::Name)]
Set Field [Container Export::Name; "Record " & Get(RecordID)]
End If
Set Variable [$path; Value:MBS( "Path.AddPathComponent"; $folder; Container Export::Name )]
Set Variable [$r; Value:MBS("Files.CreateDirectory"; $path)]
Get file in desktop folder:
Set Variable [$folder; Value:MBS( "Folders.UserDesktop" )]
Set Variable [$path; Value:MBS( "Path.AddPathComponent"; $folder; "test.txt" )]
See also
- Shell.Execute
- SyntaxColoring.AddContextMenuCommand
- Text.ReadTextFile
- Trace
- Trace.SetErrorsOnly
- Trace.SetWithTimes
- WebDownloadDelegate.SetFolder
- WordFile.AppendTableRow
- WordFile.ReplaceTag
- XL.Book.SaveToFile
Example Databases
- AVRecorder/AVRecorder
- Containers/Archive Container
- CURL/CURL Download Text to file
- DynaPDF/Merge PDFs
- DynaPDF/Shrink PDF pages
- GraphicsMagick/Create GIF
- Mac only/Allow File Drags
- Mac only/Movies/AVAsset Export Session
- Mac only/RichText/Write Document
- WebViewer/Custom WebView
Blog Entries
- How to use Trace
- New in MBS FileMaker Plugin 13.1
- Build archives on the fly
- Add page links for FileMaker
- New in MBS FileMaker Plugin 11.3
- Define hot keys for functions in the FileMaker development
- Parsing VCard file
FileMaker Magazin
This function is free to use.
Created 18th August 2014, last changed 4th June 2023
