Opening Files : Saving Files
Hi all, does Actionscript support the creation of simple text files?
For example, I want to create a new text file if one doesn't already exist, and then write to the file if the user chooses to save--just like using a streamreader etc.
If Actionscript supports these methods, could you point me to the documentation?
Thanks
Actionscript 2.0
Posted on: Thu Feb 15, 2007 4:34 pm
View Complete Forum Thread with Replies
Sponsored Links:
Saving Html Files As Cfm Files
In older versions of Flash it was possible to tell the html publish setting to be saved with a cfm extension. I am having a hard time seeing how that can be done in the new version CS3. I go into the publish setting and give the file a cfm extension but when it exports it looks like this, ",html.cfm" it's just a pain to have to go back and change the extension after the fact. Am I missing something in the new version?
Thanks,
View Replies !
View Related
Linking Files - Opening Files
I am a novice on a steep learning curve!
I have just taken over a project with lots of flash/swf files which I think probably should have been setup as one file with many scenes. Is it possible to link from one file to another or will I have to start from scratch and copy and paste assets etc.
Also is it possible to create an action script for a 'button' to open a PDF file from within the movie similar to opening a URL?
View Replies !
View Related
Saving .pdf Files
Hello everyone,
I'm working on a cd presentation in flash and I need to be able to allow the user to save a .pdf file and a .xls file to their computer when they click on a button.
I also wanted to know if you could launch the file in the application from flash also, for example a user might click on the button of the mac version of a pdf, and it would open the pdf up in acrobat right from flash.
Are both of these possible to do? If so, can someone please help me. it's really urgent!!!
Thanks
[Edited by ajeanne22 on 06-28-2001 at 02:56 PM]
View Replies !
View Related
Saving Files
Please help, Is there anyway that I can save a flash file on my machine using Actionscript or any flash command. Example: I have the ability to edit a field in the Flash Player and I want to click a save button and save an swf or exe file on my machine.
View Replies !
View Related
Saving .swf Files
I have had my kool moves for a year or more and recently it won't let me edit a file and then save it with the change. It seems to change it and save it, but when I go to upload it to my server, it doesn't reflect the change. As well as it no longer saves as a webpage. What should I do to fix this?
View Replies !
View Related
Saving Files?
I wish to make it possible for the user to save a file to their cookies and load it up later. Does it involve PHP or other SSLs to do this? If so, where can I find a tutorial? Otherwise, where can I find a tutorial? Heh, thanks
View Replies !
View Related
Saving FLA Vs SWF Files Qs ?
I've completed my Movie and now I wish to Imbed it into another Format. I already know how to do this but I am having a little problem. Since I spent a lot of time revamping the structure of my Movie, I found that I created an enormous amount of Images & Buttons that I was no longer using. After I Deleted these unnecessary Images and basically streamlined the Movie, I Saved it with a Different Name. Now when I went to the other Format I mentioned to Import the SWF Files, they were no were to be found. My FLA Files are there but not the swf files. So can someone explain to me why this happened and how I can locate or create an swf file for my newly renamed Flash Movie?
View Replies !
View Related
Saving Files
I'm fairly new to flash, but I was reading tutorials and I learned how to load in outside variables from other files (eg. text document), but I want to create a game in which it saves files to a text document so I can load them later. Can someone please tell me (in a very simplified way, if possible) how to save data to text files from flash?
View Replies !
View Related
Saving Files
Hi everybody,
I need to make it possible to download files from my movie... Like an image bank with a button that allows users to download the file with out having to launch an application so they can save it where ever they want in their hard drives (with a browse option)...
Can anybody help? ...pleeeze?
-- Ana Duke
View Replies !
View Related
Saving Files
Hi all,
I really need some help over here. I need to do a game that register high scores for the player and able to store the files up to a server to the computer. Anyone got any recommendations or simple codes?
I read through some PHP and mySQL but I really couldn understand. Is there a step by step tutorial?
Any help would be much appreciated. Thank you.
View Replies !
View Related
Saving Files
I would like to open a save file dialogue box on the click of a button within a flash projector. I need to allow people to save particular content from a cdrom to their hard drives. Is there any way of doing this?
many thanks
View Replies !
View Related
Saving Local Files
Hi.
I know director has a way for you to be able to save a file or folder from the cd to your hardrive. Since I do not know how to use director, is there a way yo ucan d this in flash?
your help would be greatly appreciated!
View Replies !
View Related
Saving Text Files?
All,
I am trying to open, edit and save text files in MX via a Input text field.
Loading a text file is easy.
Saving is not.
I know I need to use FS in projector. But where can I find an easy way to save text files? A tutorial etc?
It's likley I will only need to do this on a PC, not live on the web
Thanks for your help in advance!
View Replies !
View Related
Saving Files To Disk
I think I posted this question last week sometime but I got no repsonce. Anyway I'm in the process of making a CDrom splash screen in flash. I have various links to documents on the the CDrom.
Some of these links I want to directly download the files to the Hard drive. (just like if you right click and save-as in IE).
Can anyone tell me how to go about doing this??
View Replies !
View Related
Saving Files From Internet
I am a graphic designer and am working on a self-promo cd that will go to very specific clients that will show work different than what is currently on my site. There are a number of flash intros that I would like to embed into the cd. I have permission from the client to link to the site, but no longer have access to the fla or swf files. Is there a way to save these files off the interent? I can get the html. but not the swf. The sites are currently live.
designfireside
View Replies !
View Related
Saving Get/url Music Files?
Thanks ahead of time for any help anyone can be.
I have a music/design Flash website where the user can click on a song title of a CD and hear the downloaded(GET/URL self) mp3.
The problem is how to save the file to the desktop of the user for future listening or burning or whatever.
Is this possible?
Go to:
www.bluewoods.com
click on MUSIC
click on CD's
click on CD Titile
click on Song Title to play mp3
View Replies !
View Related
Saving Input To SWF Files
Hi:
I was wondering if anyone knows how I can save input information ie: Movie Clip states either on or off without creating an online database.
I would like the "state" to be saved even after the computer has been shut down so next time when the user boots up again the state is remembered.
Please help ...
View Replies !
View Related
Best Practices?: Saving Files Throughout The Day
Please feel free to recommend a better thread if necessary for this post...
In timeline code, as I developed a project I would save my files with incremented fla file names a few times throughout the day, generally just before I was about to break it again as I worked on a new part.
But, as I move more code into external .as files, especially in 3.0, I'm not sure how to keep my "safe" versions. I can't increment the file name, because the file name is an integral part of the structure. I'm finding that I'm no longer saving myself the "Oh crap, how did I break this thing?!" back-ups because I just don't have a good method of incrementally saving my work throughout my day or milestones.
Does anyone have some suggestions on how they work on a multiple day/week project while keeping a logical back-up a few times a day or whenever they are at a functional milestone?
View Replies !
View Related
Saving Files Locally
Hello everybody,
I'd like to give users the possibility to save a txt file or a html file locally. With MMsave command I could do it but I can't let user to choose where the file must be saved. There's another method to do that?
View Replies !
View Related
Saving FLA Files On Your Web Server
I've been told never to save my FLA files on the Web server, however, I'm finding that my SWF files won't work unless I have both the SWF file and the FLA file on the Web server. What am I doing wrong?
Edited: 12/10/2006 at 09:14:12 PM by UMIWebbie
View Replies !
View Related
Saving Sound Into Files
Hello,
I want to record audio using the microphone, for say one minute or so. This I know how to do.
Then the recording should be saved on the server, as wav/mp3/other, as a sound file that can be loaded into flash again later on.
What is the best way to do this kind of functionality and what apps are required?
Would I need to use Flash media server?
Please help! Thanks!
//jim
View Replies !
View Related
Saving Variables In Files
*Please forgive me my bad english*
Is it possible to make such a thing:
When Button_btn is clicked (onRelease), var( var Name:String = new String("Flash MX|) ) is send to file (File.txt) and saved there. I think its something with PHP. I dont know php...
Thanks, for help.
View Replies !
View Related
Saving Files On A Server
Is it possible to save files on a server from a flash movie?? I want to build a Contact Us form, however the server were I store my website does not support PHP, so I was thinking maybe I could make a contact form that insteadof sending an e-mail it would save a new test document on the server side!!
Is this possible?, and if yes how can I do it?
Thanks in adavance to all!
View Replies !
View Related
[Help] Saving Files In A Specified Folder.
Is it possible, either with AS1.0 or as2.0 to save a text file and create folders from flash in a specified directory?
I know how to use sharedObject, but I was wondering if there was any way to save files to other locations or even create a folder to save them into.
Thanks!
View Replies !
View Related
Trouble Saving Files. :(
I'm developing Flash for a CD.
I want to create a button for the user to click and then have a choice to save or open file (like PDF or Word file).
i have the following code:
ActionScript Code:
myButton.onRelease = function(){ getURL("abc.doc");}
I can't see anything wrong with the above.
I intend to use the code for a CD ROM.
abc.doc will sit on the CD ROM.
When I click on the button, it opens a browser window and tries to go to google.com.
I had it working the other day.
See the attached files.
Need help urgently!
Thanks.
OM
View Replies !
View Related
[AIR]Saving Files To SharedObject
I am doing a mp3 player like a Winamp
I can get names and urls of droped files.Then I use Sound class to play them. There is no problem.
But when user close my player and open again, the files must be on the list... I thought to use Shared Objects.
This my droped file code:
ActionScript Code:
var file_list:SharedObject = SharedObject.getLocal("files");d = e.clipboard.getData(ClipboardFormats.FILE_LIST_FORMAT) as Array;file_list.data.sounds = d.toString();
You see it is array.No problem here.Then my first codes:
ActionScript Code:
var file_list:SharedObject = SharedObject.getLocal("files");if (file_list.data.sounds!=null) { d=file_list.data.sounds.split(",") trace(d);}
In output:
Code:
[object File],[object File],[object File],[object File]
Yes you think there is no problem.But yes there is I can't get the files names or urls.The error like this:
Quote:
TypeError: Error #1034: Type Coercion failed: cannot convert "[object File]" to flash.filesystem.File.
at deneme0_fla::MainTimeline/baslik_yarat()
at deneme0_fla::MainTimeline/deneme0_fla::frame1()
at runtime::ContentPlayer/loadInitialContent()
at runtime::ContentPlayer/playRawContent()
at runtime::ContentPlayer/playContent()
at runtime::AppRunner/run()
at global/runtime::ADLEntry()
First of all can we save our files? If yes how? Thanks...
View Replies !
View Related
Saving Files From Pc To Mac In Flash 5
i have a pc and i made a flash presentation and i publish the swf and
the mac and pc projectors.everything works fine but the mac projector doesn't
and that the really only thing i need.
my question is : can i publish a mac projector on pc and burn a CD with it
and open it on a mac computer? if so what are the procedures? or do i need
to open the flash (Fla)file on a mac and then publish the mac projector?
it looks that the mac projector i made on pc is somehow read by the mac as
a compressed file but it doesn't work.
i don't know much about flash and this is probably a stupid question.
please help and i apologies in advance for any lexical mistakes.
thankyou,thankyou,thankyou
massimo
View Replies !
View Related
Saving Files On A Server
Is it possible to save files on a server from a flash movie?? I want to build a Contact Us form, however the server were I store my website does not support PHP, so I was thinking maybe I could make a contact form that insteadof sending an e-mail it would save a new test document on the server side!!
Is this possible?, and if yes how can I do it?
Thanks in adavance to all!
View Replies !
View Related
Trouble Saving Files. :(
thanks for all of the replies.
i'm really pulling my hair out over this one.
I have the following code:
ActionScript Code:
myButton.onRelease = function()
{
getURL("abc.doc");
}
I can't see anything wrong with the above.
I intend to use the code for a CD ROM.
abc.doc will sit on the CD ROM.
When I click on the button, it opens a browser window and tries to go to google.com.
I had it working the other day.
Need help urgently!
OM
View Replies !
View Related
Saving Dynamic Files
http://www.redonegroup.com/saving_files_as3/
I have this code:
Code:
package
{
import flash.display.Sprite;
import flash.display.StageAlign;
import flash.display.StageScaleMode;
import flash.events.Event;
import flash.events.MouseEvent;
import flash.net.*;
import flash.text.TextField;
import flash.text.TextFieldType;
import flash.text.TextFormat;
public class SavingToTextFiles extends Sprite
{
private var txt_title:TextField;
private var txt_title_input:TextField;
private var txt_img:TextField;
private var txt_img_input:TextField;
private var txt_comment:TextField;
private var txt_comment_input:TextField;
private var txt_send:TextField;
private varstatus_txt:TextField;
private var txt_format:TextFormat;
private var myData:URLRequest;
private var variables:URLVariables;
private var loader:URLLoader;
private var numOfObject:uint;
public function SavingToTextFiles ()
{
init();
}
private function init() : void
{
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;
buildForm();
trace(this);
trace(this.getChildAt(0).name);
trace(this.numChildren);
}
private function buildForm () : void
{
txt_title = new TextField ();
txt_title.text = "Title: ";
txt_title.x = 50;
txt_title.y = 50;
txt_title_input = new TextField ();
txt_title_input.background = true;
txt_title_input.width = 180;
txt_title_input.height = 20;
txt_title_input.x = 110;
txt_title_input.y = 50;
txt_title_input.type = TextFieldType.INPUT;
txt_img = new TextField ();
txt_img.text = "Image: ";
txt_img.x = 50;
txt_img.y = 80;
txt_img_input = new TextField ();
txt_img_input.background = true;
txt_img_input.type = TextFieldType.INPUT;
txt_img_input.width = 180;
txt_img_input.height = 20;
txt_img_input.x = 110;
txt_img_input.y = 80;
txt_comment = new TextField ();
txt_comment.text = "Comment: ";
txt_comment.x = 50;
txt_comment.y = 110;
txt_comment_input = new TextField();
txt_comment_input.background = true;
txt_comment_input.type = TextFieldType.INPUT;
txt_comment_input.x = 110;
txt_comment_input.y = 110;
txt_comment_input.width = 180
txt_comment_input.height = 60;
txt_send = new TextField();
txt_send.selectable =false;
txt_send.text = "send";
txt_send.height = 20;
status_txt = new TextField();
status_txt.x = 50;
status_txt.y = 10;
status_txt.width = 200;
status_txt.height = 20;
status_txt.text = "";
var s:Sprite = new Sprite;
s.buttonMode=true;
s.x = 265;
s.y = 175;
addChild(txt_title);
addChild(txt_title_input);
addChild(txt_img);
addChild(txt_img_input);
addChild(txt_comment);
addChild(txt_comment_input);
addChild(status_txt);
s.addChild(txt_send);
addChild(s);
s.addEventListener(MouseEvent.MOUSE_DOWN,sendData);
}
private function sendData (e:MouseEvent) : void
{
if(txt_title_input.text != "" && txt_comment_input.text != "" && txt_img.text != "")
{
myData = new URLRequest("http://www.redonegroup.com/saving_files_as3/save.php");
myData.method = URLRequestMethod.POST;
variables = new URLVariables ();
variables.Title = txt_title_input.text;
variables.Comments = txt_comment_input.text;
variables.Image = txt_img_input.text;
myData.data = variables;
loader = new URLLoader ();
loader.dataFormat = URLLoaderDataFormat.VARIABLES;
loader.addEventListener(Event.COMPLETE,dataOnLoad);
loader.load(myData);
}else {
status_txt.text = "All Fields are mandatory";
}
}
private function dataOnLoad (e:Event) :void
{
if(e.target.data.writing == "Ok")
{
status_txt.text="Submited data was saved";
}else {
status_txt.text="Error in saving submitted data";
}
}
}
}
And its giving me this error:
Error: Error #2101: The String passed to URLVariables.decode() must be a URL-encoded query string containing name/value pairs.
at Error$/throwError()
at flash.net::URLVariables/decode()
at flash.net::URLVariables$iinit()
at flash.net::URLLoader/flash.net:URLLoader:nComplete()
here is the php code
PHP Code:
<?php
//Capture data from $_POST array
$title = $_POST['Title'];
$comments = $_POST['Comments'];
$image = $_POST['Image'];
//Make one big string in a format Flash understand
$toSave ="Title=$title&Comments=$comments&Image=.$image";
//Open a file in write mode
$fp = fopen("http://www.redonegroup.com/saving_files_as3/save.txt", "w");
if(fwrite($fp, $toSave)) echo "writing=Ok&";
else echo "writing=Error&"
fclose($fp);
?>
can anyone help me out what is wrong, Please! ?
View Replies !
View Related
In Need Of Help In Saving And Reading Text Files
I have sat and struggled for days on trying to get a perl script (file is a .pl) to save Flash variables to a text file and then have flash be able to read the file later on. I can't get the perl script to save outside the cgi-bin or the Flash file to read from a text file within the cgi-bin. As you can tell I know little about perl, and I am absolutely out of ideas. If anybody could help me, I would be so gracious. All the script has to do is to take variables from a flash file save it to a txt file, allow for future alteration, and then allow the flash file to read the text file. This has probably already been answered somewhere.
Thanks so much to whoever can help me.
chadz6
View Replies !
View Related
Saving Multiple Text Files
I'm developing an executable flash-based editable presentation in Flash 5 to compete with Powerpoint. It's pretty simple, the user can edit the presentation, and change the text, and the data in the included charts. The user can then save the data into an external text file using
Code:
fscommand ("save", "data.txt");
Now, we would like to add the option to save multiple versions of the variables. That's easy. But we also want Flash to be able to save information about the versions, specifically a name and a date created.
The easiest way I can think of is to create a seperate text file that contains only the name and modified dates of the files, which flash can use. Now, here's the question: can I use the "save" FScommand and Load Variables to deal with a small portion of the variables, or do they only save all data, and replace all variables in the file?
View Replies !
View Related
Loading/saving Ext Files From Flash Mx
Hi all,
I've been looking around for a while to see how to load external files into flash, and how to save flash content to a hard drive. But the solutions only seem to be for txt files. I was wondering if it was possible to have a word document or a PDf loaded into a flash movie, and then have it so that someone could save them to their hard drive?
Is this possible? Or would I have to learn some advanced actionscript, perl, etc...?
I'm creating a edu-tainment flash game in which I want to give the users the opportunity to not only print, but to save stuff as well.
Many thanks if you can help.
View Replies !
View Related
Saving Files To Users Desktop
Need to know how to point to a file that is on a cd that the flash movie is playing from and saving that file to the user's desktop without opening up the file in it's respective application.
Ex. using the get url command and pointing it to a pdf file automatically opens acrobat. Need it to save to desktop instead.
Thanks
Vivid1
View Replies !
View Related
Saving Files To Hard Disk
I have a flash projector being used as a splash screen for a cdrom..
I have several buttons opening PDF's but I also want some buttons that will save fiel directly to the HD. can anyone tell me how this is done?
Thanks
View Replies !
View Related
Saving External Files In Flash
say I have 2 files
myflashdocument.swf
text.txt
I know how to load the variables from the "text.txt" file, but i have no idea how, or if, it is possible to edit and save "text.txt" from my swf file. so obviosly, i need the actionscript.
View Replies !
View Related
[MX04] Saving To External Files?
Yeah... there's a thread already about writing to external .txt or similar, and i found this but it didn't work for me (status: failed save).
I almost gave up hope... then I saw this meaning there could be hope for me!
You see what I'm doing isn't web/browser based =)
Unfortunately I still don't have a clue how to save to an external file, I can load, just not save.
Let me tell you my project. I've made a game, all done and complete. It's decent but not quire finished, and works on external map files and stuff. I've also made a MAP EDITOR for it, and it all works fine and generates a final string that can be read by the game in a map file.
ALL I NEED IS A WAY TO WRITE THIS STRING INTO A FILE THROUGH THE FLASH!!!! :S
Thanks in advance for your help and stuff.
View Replies !
View Related
|