Print at Dec 19, 2025, 9:29:21 PM
Posted by Larnorsh at Mar 21, 2013, 11:47:51 AM
Can't change the directory settings using -D option in SweetHome3D.l4j.ini file
Hi,

I'm trying to use the option to change directory settings described at http://www.sweethome3d.com/javadoc/com/eteks/sweethome3d/SweetHome3D.html.

I have created a SweetHome3D.l4j.ini file stored in the same directory as SweetHome3D.exe with the parameters
-Dcom.eteks.sweethome3d.applicationFolders="C:\Egt\Etek\RunDir\Sweet Home 3D" and
-Dcom.eteks.sweethome3d.preferencesFolder="C:\Egt\Etek\RunDir\Sweet Home 3D".

But when I start SweetHome3D and open a project or load a furniture library it still use the "C:\Documents and Settings\user\Application Data\eTeks\Sweet Home 3D" path and my roaming profile exceeds its limitation. I don't want to have anything stored under my roaming profile because I have to delete everything before i can log off my computer.

How shall I specify this option to get it work?

Posted by Puybaret at Mar 21, 2013, 1:41:41 PM
Re: Can't change the directory settings using -D option in SweetHome3D.l4j.ini file
Please set the com.eteks.sweethome3d.tools.temporarySubFolder System property with a subdirectory directory relative to the default one (i.e. C:\Documents and Settings\user\Application Data\eTeks\Sweet Home 3D under Windows Vista/7/8). With the -D option you used, it could give for example:

-Dcom.eteks.sweethome3d.tools.temporarySubFolder=..\..\..\..\..\Egt\Eteks\RunDir\Sweet Home 3D\work

So, in the current version, if you want a completely different directory, you'll have to use ".." symbols to go to the parent directory until the root, then go to the directory of your choice (still on the same drive). Hope you can handle it.

I would prefer that the temporary files found in this directory are automatically deleted at program exit, but there's a bug in Java under Windows I don't think Oracle fixed it yet. Nevertheless, temporary files older than a week are automatically deleted at program launch.
----------------------------------------
Emmanuel Puybaret, Sweet Home 3D creator

Posted by Puybaret at Jun 5, 2013, 2:08:13 PM
Re: Can't change the directory settings using -D option in SweetHome3D.l4j.ini file
From version 4.1, you can also set an absolute path in the com.eteks.sweethome3d.tools.temporarySubFolder system property.

Note also that I found how to apply the workaround proposed in the bug #6962458, so temporary files created by Sweet Home 3D will be automatically deleted at program end if necessary.
----------------------------------------
Emmanuel Puybaret, Sweet Home 3D creator