download images from CD and set it as wallpaper

Hello All,

I am creating an entertainment CD using flash. Some of the contents are Desktop wallpapers and screensavers. Until a couple of days ago my approach was to just have a set of instructions detailing the process of going into a folder on the CD and copying it to the desktop… Yada yada yada, then I stumbled across Applescripting. With the FsCommand I am able execute Applescript and I had no Idea how powerful it was.

I have the screensaver issue working pretty well but I’m not so sure about the Wallpaper thing.

My question is how could I best approach this. It would be great if I could do it in one foul swoop but maybe that’s asking too much. Is there a way to do this? At the very least I think it would be nice to be able to unzip the Wallpaper folder to the users computer allowing them to choose the destination. Or simply copy it from the CD to a user defined folder on the hard drive.

I’m very new to this so any advice would be greatly appreciated.

Thanks,
Joe

The unzip process is a harder question, depends on what the user has to unzip a file and what you’re comfortable using(Stuffit or tar are possibilities). However, the file copy is very easy in AppleScript. Let’s assume the CD is named “CD” and the file is “wallpapers.zip.” To copy it to the user’s desktop would be:

tell application "Finder" to copy file "CD:wallpaper.zip" to the desktop

Yeah, it’s that simple. If you want to put it where the user says to put it, use:

tell application "Finder"
	set myfolder to choose folder with prompt "Where do you want the wallpaper file?"
	copy file "CD:wallpaper.zip" to myfolder
end tell

Hope this helps! :slight_smile: