Exporting GIF out of Illustrator

I am working on a script to export GIF files out of Illustrator CS 2. I have gotten the script below to work, but I cannot control any of the GIF export options. Even though I change the scale factor, the gif file comes out the same size. I can control the export options for JPEG.

Has anyone tried this? Any suggestions?

Thanks,
Don

tell application "Finder"
	if folder "Export For Web" of desktop exists then
		set myExportFolder to (folder "Export For Web" of desktop) as string
	else
		set myExportFolder to (make new folder at desktop with properties {name:"Export For Web"}) as string
		
		
		
	end if
end tell
tell application "Illustrator CS"
	tell the front document
		set FileName to name
		set filenamewords to words of FileName
		set Orig_Limiter to AppleScript's text item delimiters
		set AppleScript's text item delimiters to "-"
		set FileNameDash to filenamewords as string
		set AppleScript's text item delimiters to Orig_Limiter
		set myfilegif to myExportFolder & FileNameDash & ".gif"
		
		
		export to file myfilegif as GIF with options {antialiasing:false, artboard clipping:false, color count:12, color dither:none, color reduction:adaptive, dither percent:88, horizontal scaling:800, saving as HTML:false, vertical scaling:400, information loss:0, interlaced:false, matte:true, matte color:{255, 255, 255}, web snap:0, transparency:true}
		
	end tell
end tell
tell application "Safari"
	activate
	open myfilegif
end tell

I asked a scripting associate this question and I got this reply, for those interested:

You had problems in two areas both dealing with class and super class. Here the fix:

export to file myfilegif as GIF with options {class:GIF export options, antialiasing:true, artboard clipping:false, color count:128, color dither:none, color reduction:adaptive, dither percent:88, horizontal scaling:800, saving as HTML:false, vertical scaling:400, information loss:0, interlaced:false, matte:true, matte color:{class:RGB color info, red:255, blue:255, green:255}, web snap:0, transparency:true}

You have to explicitly tell the options which export options you are going to use. Similarly, you have to tell matte color what color space you plan to use and then which colors are going to be modified.

Just as a side note: You only need to include those parameters and options that are changing, so the whole line could be shortened to:
export to file myfilegif as GIF with options {class:GIF export options, color dither:none, color reduction:adaptive, horizontal scaling:800, vertical scaling:400, matte color:{class:RGB color info, red:255, blue:255, green:255}}