One of my projects does FTP/SFTP downloads. While the user can select location, right now I am using SpecialFolder.Desktop as the default. ~/Downloads would be better practice. However, a SpecialFolder.Downloads does not exist (#41113), and I fear localization problems, among other things, if I use simple paths.
From that feedback case, the Mac-side workaround is supposed to be...
Function DownloadsFolder() As FolderItem
Const kUserDomain = -32763 //I did 'theDomain as Integer=SpecialFolder.DomainUser' instead.
Const kDownloadsFolderType = "down"
Return SpecialFolder.GetFromDomainAndCode(kUserDomain, kDownloadsFolderType)
This works on 2019r1.1, but on r2 the function returns ~/Library. I tried messing around with "garbage" four letter strings. These predictably threw NilObjectExceptions on r1.1. On r2, though, I got ~/Library no matter what I did, crashing only if I gave an empty string. Filed #58188 on this one.
Yes, a SpecialFolder.Downloads would be nice, especially with a workaround apparently broken. Meanwhile, on the Windows side I am getting into the weeds with Declares, trying to figure this out based on VB and C# code I've found. Usually, when I've gotten to this point in the past, Christian has bailed me out. :-)