5 Replies Latest reply on May 15, 2006 5:14 AM by Newsgroup_User

    Force imported AVI location on startMovie

    Level 7
      Hi

      We have imported AVI files as QT (selected QT when importing), we find
      that when we publish the movie burn to dvd and run it on another
      computer it does not work as it is looking for the AVI File.

      We are using this script in on StartMovie:


      set myDelimiter = the last char in the moviePath

      member (open"Cast Member Name").filename = the moviePath & "Movies" &
      myDelimiter & "movie name.avi"

      We are reciving the error:

      Script Error: Variable used before assigned a value
      member (open"Cast Member Name").filename = the moviePath & "Movies" &
      myDelimiter & "movie name.avi"

      Any advice would be much appreciated

      Thanks
      B


        • 1. Re: Force imported AVI location on startMovie
          Level 7
          You've only shown part of your code so its difficult to guess what might
          be wrong. Director may be objecting to open "Cast Member Name" as this
          makes no sense in Lingo. Open is a command. You don't normally place
          commands inside a space where Director is looking for a file name or a
          reference to a file name.

          If "Cast Member Name" is a variable, then the variable name needs to be
          one word and shouldn't have quotes around it. If it is something else
          then please explain.

          In any case, you should not need any of this. If you have your .avi
          files and the folder that holds them in the same relative location on
          the DVD as you had during authoring on the hard drive, then Director
          will use that same relative path to find the files. If you change the
          location between authoring and playback, Director won't find the files.

          Trying to solve the path problem in a StartMovie function is too late in
          the start up process. A startMovie function doesn't run until after the
          first frame of the movie is on the screen. Director will try and resolve
          external file paths well before the first frame is drawn.

          --
          Rob
          _______
          Rob Dillon
          Adobe Community Expert
          http://www.ddg-designs.com
          412-243-9119

          http://www.macromedia.com/software/trial/
          • 2. Re: Force imported AVI location on startMovie
            Level 7
            Hi Ben,

            I agree with Rob said. Trying to write a script to locate the file is just
            patching up something done incorrectly in the first place. So, it's better
            to go to the source of the problem and maintain the same path structure to
            the video file as was the case when you imported it.

            On another issue, is there any reason you're using an AVI but treating it
            as a QT cast member? Why not simply use a QT video? The advantage of using
            an AVI is that you won't require additional software when playing it on a
            PC. If you play an AVI through QT, your end user will need QT installed.

            regards
            Dean

            Director Lecturer / Consultant
            http://www.fbe.unsw.edu.au/learning/director
            http://www.multimediacreative.com.au

            • 3. Re: Force imported AVI location on startMovie
              Level 7
              Ben wrote:
              > set myDelimiter = the last char in the moviePath

              It's
              myDelimiter=the last char of the moviePath

              not "in".

              Andrew


              • 4. Re: Force imported AVI location on startMovie
                aldus Level 1
                Hello Ben
                quote:

                member (open"Cast Member Name").filename = the moviePath & "Movies" &

                Definitly wrong: member(open ... ???
                What do you want to open ...?
                ---
                myDelimiter = the last char of the moviePath
                member (open"Cast Member Name").filename = the moviePath & "Movies" &
                myDelimiter & "movie name.avi"
                ---
                A better way in my opition is to set the searchpath: (hih)

                • 5. Re: Force imported AVI location on startMovie
                  Level 7
                  aldus wrote:
                  > A better way in my opition is to set the searchpath: (hih)

                  IMO, absolutely, definitely not. It is better to tell it *exactly* where to
                  find the file than to fudge it by giving it a list of locations to look for
                  the file.

                  Andrew