Indigo Rose Software

Professional Software Development Tools

 
Results 1 to 15 of 15
  1. #1
    Join Date
    Jun 2006
    Posts
    36

    Error: Can't write the file

    Hi

    I'm currently working on a project with flash files saved as exe not swf. After publishing the project on CD
    I got this error "Flash in a shell Error: Cant write the file".

    I get this error when I only run the project from the CD, but when I run it from the computer it works properly.

    And also it runs properly if it is published as EXE file, even it is run from the CD. If I use the EXE format, my project will be very slow because there are many files included.

    How can I solve the problem?

    a sample from my project and the error screenshot are attached.


    Thanks
    Attached Files

  2. #2
    Join Date
    Jun 2006
    Posts
    36
    Sorry, here is the screenshot of the error.
    Attached Images

  3. #3
    Join Date
    May 2006
    Posts
    5,380
    your flash file is trying to write a file on the cd, which it cant

    i dont know how the flash exe thing works, but it seems that its trying to write a file, maybe it needs this file to run, settings or something like that

    try copying the file to a temp folder and run it from there so it can write the file to the hdd and not the cd
    Open your eyes to Narcissism, Don't let her destroy your life!!

  4. #4
    Join Date
    Jun 2006
    Posts
    36
    Thanks RizlaUK,

    As I said before, when I run the project directly from the hdd it works without problems. The problem only occurs when I copy the project and run it from the CD. And this problem doesn't occur if the project is published as EXE even if I run it from the CD.

    Any suggestion?

    Thanks

  5. #5
    Join Date
    May 2006
    Posts
    5,380
    like i said above, try copying the file to a temp folder and run it from there so it can write the file to the hdd and not the cd

    Code:
    File.Copy(_SourceFolder.. "\\file.exe", _TempFolder.. "\\file.exe", true, true, false, true, nil); 
    err= Application.GetLastError(); 
    if (err ~= 0) then 
        Dialog.Message( "Error", _tblErrorMessages[err], MB_OK, MB_ICONEXCLAMATION); 
    else 
        result = File.Run(_TempFolder.. "\\file.exe", "", _TempFolder, SW_SHOWNORMAL, false); 
    end
    output enhanced with AMS Code Pretty
    Open your eyes to Narcissism, Don't let her destroy your life!!

  6. #6
    Join Date
    Jun 2006
    Posts
    36
    Thanks for your reply and sorry to bother you.

    Where should I put the code?

    and if I have 20 files, will it be the same code for all files?

    Thanks

  7. #7
    Join Date
    May 2006
    Posts
    5,380
    yes, just change the path and filename for each file

    if you give more detail i can help more,

    how are you launching the files.....listbox....button....???
    Open your eyes to Narcissism, Don't let her destroy your life!!

  8. #8
    Join Date
    Jun 2006
    Posts
    36
    I have a seperate page for each file with a button
    in each page to launch the files.

    And I use Quick Action "Run Program"
    AutoPlay\\Docs\\ABC_song\\abc_song.exe

    and the working folder:
    AutoPlay\\Docs\\ABC_song


    Thanks

  9. #9
    Join Date
    Jun 2006
    Posts
    36
    Quote Originally Posted by RizlaUK View Post
    like i said above, try copying the file to a temp folder and run it from there so it can write the file to the hdd and not the cd

    Code:
    File.Copy(_SourceFolder.. "\\file.exe", _TempFolder.. "\\file.exe", true, true, false, true, nil); 
    err= Application.GetLastError(); 
    if (err ~= 0) then 
        Dialog.Message( "Error", _tblErrorMessages[err], MB_OK, MB_ICONEXCLAMATION); 
    else 
        result = File.Run(_TempFolder.. "\\file.exe", "", _TempFolder, SW_SHOWNORMAL, false); 
    end
    output enhanced with AMS Code Pretty


    Hi again

    I tried this code one one file and I got the same error
    but this time also even when I run the file from the HHD

  10. #10
    Join Date
    Oct 2006
    Location
    Somewere over the rainbow
    Posts
    314
    are you sure that its not write/read protected?

  11. #11
    Join Date
    Jun 2006
    Posts
    36
    Yes, it is not write/read protected.

  12. #12
    Join Date
    Jun 2006
    Posts
    36
    Plz, any idea to solve the problem?

  13. #13
    Join Date
    May 2006
    Posts
    5,380
    the example you posted has "abc_song.exe" and also has a directory called "Data", the files in the Data directory are the support files for the flash exe file, you will need to copy that directory to the temp folder as well

    here, i took your files and put then into a zip file,

    this will extract the zip to a temp folder and run the exe
    Last edited by RizlaUK; 02-01-2009 at 11:35 AM.
    Open your eyes to Narcissism, Don't let her destroy your life!!

  14. #14
    Join Date
    Jun 2006
    Posts
    36
    Thanks RizlaUK,

    everything is working well now.

  15. #15
    Join Date
    May 2006
    Posts
    5,380
    no problem, glad you got it in the end
    Open your eyes to Narcissism, Don't let her destroy your life!!

Similar Threads

  1. Best way to share custom buttons with the group?
    By mwreyf1 in forum AutoPlay Media Studio 6.0
    Replies: 10
    Last Post: 04-28-2010, 01:29 PM
  2. Error 3038: Could not seek in compressed file
    By Rikard in forum Setup Factory 7.0
    Replies: 2
    Last Post: 05-25-2006, 11:55 AM
  3. Can search allow manual browse even if file is found?
    By RichardShaw in forum Setup Factory 5.0
    Replies: 2
    Last Post: 08-28-2000, 06:08 PM
  4. Replies: 0
    Last Post: 08-17-2000, 02:29 PM

Posting Permissions

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