From: Simon Staton Date: 2009-08-14T17:49:08+09:00 Subject: Re: newbie question making a folder with ruby Fleck Jean-Julien wrote: > Hello, > >> all that is doing is adding a new toolbar and opening somthing called a >> components panel. now is it possible to add code in here that will >> create a folder on there C: called temp and if it is already there dont >> overwrite it. > > Sure. > I'll suppose you are on a UNIX system type (I do not know that sort of > thing on windows, perhaps, it is as simple as changing /temp by > c:/temp or c:\temp) > > Just add: > > dir = "/temp" > > if File.exist?(dir) > puts "#{dir} already exists !" > else > Dir.mkdir(dir) > end > > Cheers, ok I have got another error this is the error it is giving, http://www.actinictesting.co.uk/error.jpg any ideas? I am a noob when it comes down to programming etc and have oinly ever used ruby on plugins. so im not sure what a unix stystem type is :p but if it helps im on windows :D -- Posted via http://www.ruby-forum.com/.