Home Tutorials Forums Articles Blogs Movies Library Employment Press Buy templates

Go Back   ActionScript.org Forums > Desktop, Mobile and non-browser Environments > Projectors and CDs

Reply
 
Thread Tools Rate Thread Display Modes
Old 05-23-2002, 07:44 AM   #1
nischal
Registered User
 
Join Date: May 2002
Location: India
Posts: 2
Send a message via Yahoo to nischal
Unhappy How to write a text file in flash

Hello flash programmer,

I want to write into a text file using flash actiona script. Is that at all possible in Flash 5 or in flash MX? if yes, then how please forward the code or a link of the URL where it is explained.
nischal is offline   Reply With Quote
Old 05-23-2002, 09:26 AM   #2
mad_A
The Zen of ActionScript
 
mad_A's Avatar
 
Join Date: Mar 2001
Location: Dublin, Ireland
Posts: 713
Default

I can't say for MX, but I know that it is not possible directly in flash 5. You can write to a socket and build a dll on the client machine to listen to that port, or send content to a script that will write. The basic reason you can't is browser security - if you can write to a machine then you can hack it so it is better that someone cannot write to the machine.

If you find a work around for this let me know.
A

Last edited by mad_A; 02-22-2005 at 11:54 AM..
mad_A is offline   Reply With Quote
Old 05-23-2002, 09:37 AM   #3
nischal
Registered User
 
Join Date: May 2002
Location: India
Posts: 2
Send a message via Yahoo to nischal
Smile

Thanks Andy

my main concern is to writing a text file using flash 5 or MX but as an application. flash file will not be loaded in browser. so client machine permission is not requiered, i think so.

so do u have any suggestion for that?
nischal is offline   Reply With Quote
Old 05-23-2002, 10:01 AM   #4
mad_A
The Zen of ActionScript
 
mad_A's Avatar
 
Join Date: Mar 2001
Location: Dublin, Ireland
Posts: 713
Default

if it is a standalone app you should be able to use

on(release) {
fscommand("save","filename.txt");
}

As far as I know this does not work on Mac OS, but I am not sure - as I don't have a mac!
mad_A is offline   Reply With Quote
Old 05-28-2002, 05:57 PM   #5
Jiffy Loop
Senior Member
 
Jiffy Loop's Avatar
 
Join Date: Apr 2002
Location: Long Beach, CA
Posts: 108
Default

I just saw this posted in the Intermediate Tutorials...It might be what you're looking for...

www.actionscripts.org/tutorials/intermediate/save_a_local_copy_of_file/index.shtml

namaste!!
Jiffy Loop is offline   Reply With Quote
Old 05-28-2002, 07:01 PM   #6
Abelius
Worldkit Vote Holder
 
Abelius's Avatar
 
Join Date: May 2002
Location: Miami - USA
Posts: 815
Send a message via Yahoo to Abelius
Default

Personally, I am also playing with the idea of being able to write text to files from Flash (MX in mycase), and I think these are the options:

1) If you go server-side then a few steps are being taken away from your "burden drive", as you have plenty tools to do that, such as ASP, PHP and Perl. You can even make ASP pages that would write text to XML files which -later on- you can get the information from.

2) If you want to write stuff directly to a single -let's say- text file, then the thing gets tougher. I did see somewhere in the forums an swf file that was using some C++ program to create text files and include some words, phrases, sentences or variables into them.
basically the way to around this is to use the "exec" command from ActionScript, but as soon as I get my hands on that, I will let you know in more detail...
__________________
Cordially,
Abelius
Commuting between Birmingham, AL, Miami, FL and Beijing, China
http://www.worldkit.com
Abelius is offline   Reply With Quote
Old 08-24-2007, 10:06 AM   #7
roshankolar
kdX
 
Join Date: Jul 2007
Location: india
Posts: 44
Default

hi nischal,

I had this issue once. If you are gonna create a projector for yor file, then use MDM ZINC. it allows you to write to files and read from them. Its cool and you dont need to go towards PHP and server scripts. it also comes with lots of desktop publishing options.


roshan
creative designer
www.roshan.it.tt
roshankolar is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Dynamic flash - external text files, please help!! rickid ActionScript 2.0 2 02-25-2005 04:38 PM
CyanBlue's 5000th Post - Useful Threads List CyanBlue ActionScript 1.0 (and below) 104 02-25-2005 02:13 PM
how to have flash save to a text file, and then load that text file formattingentries Sieg ActionScript 2.0 5 11-19-2003 09:01 PM
If anyone's bored, a custom class . . . retrotron ActionScript 1.0 (and below) 22 05-24-2003 11:01 PM
copy and paste from a text file to a flash input field C! Other Flash General Questions 1 01-29-2002 09:04 PM


All times are GMT. The time now is 03:16 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2009 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.