A Flash Developer Resource Site

Results 1 to 6 of 6

Thread: need help with editing

  1. #1
    Junior Member
    Join Date
    Apr 2012
    Posts
    4

    need help with editing

    can someone help me with this? i have a notepad done in flash and i was wondering if i can get some help with moding the code around so i can save it into a folder of my choice.
    FOUND IT!!!!!!!!!

  2. #2
    Prid - Outing Nig 13's Avatar
    Join Date
    Jul 2006
    Location
    Norway
    Posts
    1,864
    not possible to save a File in Flash to a folder without the aid of a server-side scripting such as PHP
    I am back, guys ... and finally 18 :P

    BRING BACK THE OLD DESIGN!! OR AT LEAST FIX THE AS TAGS

  3. #3
    Dignitary rynoe's Avatar
    Join Date
    Jan 2003
    Location
    Earth
    Posts
    760
    It is possible with AIR.
    [SIGPIC][/SIGPIC]

  4. #4
    Junior Member
    Join Date
    Apr 2012
    Posts
    4
    then would it be possible to save it to a folder that is pre determined in the text so that when you close the notepad it won't delete it?
    FOUND IT!!!!!!!!!

  5. #5
    Dignitary rynoe's Avatar
    Join Date
    Jan 2003
    Location
    Earth
    Posts
    760
    I havn't used in much but your sposed to be able to append, read and write to a file simUlar to server side file access. It will create file if none exists.

    If the air platform is installed,this should work:
    Code:
    import flash.filesystem.*;
    
    // Create a file.
    // For this example the file will be created on the desktop.
    var file:File = File.desktopDirectory.resolvePath("myFile2.txt");
    
    // Create a file stream to write stuff to the file.
    var stream:FileStream = new FileStream();
    
    // Open the file stream.
    stream.open( file, FileMode.WRITE );
    
    // Write stuff to the file.
    stream.writeUTFBytes("Hello. This is some more text in a file.");
    
    // Close the file stream.
    stream.close();
    
    // Clean up.
    file = null;
    stream = null;
    [SIGPIC][/SIGPIC]

  6. #6
    Junior Member
    Join Date
    Apr 2012
    Posts
    4
    you know, that might work but i have no previous history with coding at all and I'm not sure if that would work with the PSP (the whole reason I'm going through this endeavor)
    FOUND IT!!!!!!!!!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center