Hi Willy

> If Exist(Use.Home&  "/Desktop) then
>     sPath = User.Home&  "/Desktop/SystemInfo.txt"
> Endif
>
> Now it turns out that this only works on systems with English language.
> Other systems translate "Desktop" into local language!!
> Like for Dutch it will be "Bureaublad" instead of "Desktop"
>
> As it is impossible for me to test for 150 different ways "Desktop" is
> written in other languages, I was wondering is there a way around this.
>
> Does the system somewhere have the original English name for Desktop
> that I can test against? Or is there any other way of solving this
> problem?

In my KDE desktop directory I found a file named .directory, which has 
all national names of the (current desktop) directory. So you have to 
search all subdirectories of home/... and look if there is a file name 
.directory and if this file have an entry of "desktop". Than you found it.

Hope that helps
Rolf

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to