We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSyntax Questions › How to save to a folder on the c:\ drive
Page Index Toggle Pages: 1
How to save to a folder on the c:\ drive ? (Read 798 times)
How to save to a folder on the c:\ drive ?
Jan 20th, 2010, 11:49am
 
I know  save("test.png"); saves to the root of the sketch folder.

It's possible to run a dos command from processing to then move it to another folder, but is is possible to save directly to the desired location

e.g.  save("c:\test\test.png");

The command obviously returns an error due to the fact the line has a backslash.

Anyone has any ideas ?
Re: How to save to a folder on the c:\ drive ?
Reply #1 - Jan 20th, 2010, 1:13pm
 
did you try save("c:/test/test.png"); ?
Re: How to save to a folder on the c:\ drive ?
Reply #2 - Jan 20th, 2010, 2:56pm
 
Or just double the backslashes. But I prefer the forward slashes (working well in XP and above) as shown by Cedric.
Re: How to save to a folder on the c:\ drive ?
Reply #3 - Jan 22nd, 2010, 7:14am
 
Thanks a lot cedric and PhiLho, both worked. I will try to rend two separate sketches from the same location.

Thanks a lot.
Page Index Toggle Pages: 1