Recover Lingo Script

I was working on a file to day when my system crashed and I didn't backup any thing but I lost all hard earned work about 3 months worth but I have a dxr file from today dose any know how I can get my cast members and lingo script back from this dxr file???
jasoncopelAsked:
Who is Participating?
 
ducketsCommented:
You can extract most cast members (except scripts) from a DXR or DCR using director itself:

Import the dcr/dxr as a cast member into a new director movie.

Place it on the stage, in sprite 1, frame 1. Make sure the playback head is on that
frame.

Next, open a script window, and paste this:
---------------------------------
on extractAssets
 
  mov = sprite(1).movie
 
  repeat with cn = 1 to mov.castlib.count
    tCast = mov.castlib(cn)
    repeat with mn = 1 to tcast.member.count
      tMem = mov.member(mn,cn)
      if tMem.type <> #empty then
        tMem.copyToClipBoard()
        newMem = new(#bitmap) -- type doesn't matter
        newMem.pasteClipboardInto()
        newMem.name = tMem.name
        newMem.unload()
        put "extracted "&tMem.name&" (mem "&mn&" castlib "&cn&" - "&tMem.type&")"
      end if        
    end repeat
  end repeat
 
end
---------------------------------

Next, check that the script type of the script you just pasted is set to 'movie' (in the property inspector).
Hit the little lightning button in the script window toolbar (recompile all scripts).

Now open the message window, and type:

extractAssets()

...and hit return. Voila, your cast is filled with the cast members from the dcr. Any script cast members
 will be empty though!
 
For recovering your script source code, you will have to attempt to recover your original dir files from your hard drive. If the .dir file is still present, but unopenable, you may be able to open the file in a text editor, and brows through until you find the lingo script.

If the .dir file appears to have been deleted from the hard drive, you may be able to use file recovery software to find it, and 'un-delete' it.
(see: http://www.google.com/search?q=recover+deleted+files )

If the .dir file seems completely unrecoverable or if the hard drive actually no longer works, you may still be able to use a data recovery company who will take your broken hard drive and extract what they can from it. This can be fairly expensive though, so you will need to decide how badly you need the original data!.
(see: http://www.google.com/search?q=hard+disk+data+recovery )


Hope this helps!
0
 
cparcellCommented:
I fear that your scripts (code) are lost.  There is no tool to recover a DIR from a DXR or DCR.  There are tools however that can recover media such as images and audio. The tool is called DirOpener, see link below.

http://www.j-roen.net/diropener/
0
 
cparcellCommented:
Boo. That is exactly what the DirOpener tool does. You couldn't split the points. Boo on you.
0
 
ducketsCommented:
Err, not in all cases it doesn't. I actually tried it on a number of my own dcr files and it failed to recover anything from any of them. Wheras my script in Director does.

Perhaps it only works for very old files, since DirOpener itself is published with quite an old version of Director.

Also, the OP didn't say whether it was even that method which recovered the file, or one of the other two suggestions I made. Anyway, thanks for the warm welcome, Charles!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.