[Gambas-user] Get the default file manager

vuott at tutanota.com vuott at tutanota.com
Fri Feb 16 23:33:55 CET 2024


...maybe, activating gb.desktop:

[code]
Public Sub Button1_Click()
     
  Dim df As DesktopFile
  Dim path As String
   
  path = "/path/of/file"  
    
  Print "The file '"; path; "' is associated with the following programs:"
 
  For Each df In DesktopFile.FromMime(DesktopMime.FromFile(path).Type)
    Print df.ProgramName  
  Next 
    
End
[/code]






16 feb 2024, 12:39 da 64xcode at gmail.com:

> Hi,
>
> I was using Desktop.Open(Path) to open the directory of the shrimp projects but now this statement opens the ide, I guess because at some point I opened a shrimp project from the file manager and the system "memorized" this action.
>
> Anyway, how can I get the name of the default application that manages the files? in my case it is Thunar because I use XFCE but what is the general way?
>
> Best regards.
>
> Martin.
>
>
> ----[ http://gambaswiki.org/wiki/doc/netiquette ]----
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20240216/b531accb/attachment.htm>


More information about the User mailing list