View Single Post
  #8 (permalink)  
Old 03-31-2008, 05:04 PM
snakemedia snakemedia is offline
Junior Member
 
Join Date: Aug 2006
Location: Germany
Posts: 28
Send a message via MSN to snakemedia Send a message via Yahoo to snakemedia
Default Re: Creating zip files by using SWFKit Pro

Quote:
Originally Posted by AndyField
I think I've found the errors I've been making - I've now successfully been able to generate a .zip file using the following code:

Code:
// get the name for the saved .zip file
var filename = Dialogs.fileSave("Zip files(*.zip)|*.zip|", "zip");
if (filename) {

	// Generating .zip file
	// creates a new zip file to get a handle
  var handle = new Object;
	handle.value = 0;
	zipCreate(handle, filename, "");

	// grab a file from the resources panel
	var file1 = getAdditionalFile("example.swf");

	//	zipAddFile
	// adds files
	zipAddFile(handle.value, filename, file1);
	
	// closes and saves the zip file
  zipClose(handle.value); 
}
What I'm still stuck on is how to have an existing .zip file in the resources section and then add two additional files to it. Any ideas?
Good Idea! I want to build a sample package installer like Mac OS X *.dmg, Linux *.deb and *.rpm and more.. How do i work with unknown zipped files?? . example Flex OS: *.fxpi. It works?

Thanks for tips . Bye SnakeMedia
__________________
Sorry I am deaf! I have problem with eys... Thanks!
Reply With Quote