Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Quicktime and Filemaker script impossible quest

Featured Replies

I use successfully this FMP and Applescript combined script from within filemaker to open clips we choose from our FMP file:
 
Let ( 
mac_path = Right ( Substitute ( Media Path; "/"; ":"); Length (Media Path) - 1);
 
"tell application "Quicktime 7"" & ¶ & 
"activate" & ¶ & 
"open " & Quote ( mac_path ) & ¶ & 
"
set the dimensions of movie 1 to {480, 270}
" & ¶ & 
"end tell"
)
 
the script calls the clip in QT and plays it
However I would like to be able to play the movie from a specific frame
 
I have this Applescript which works perfectly within FMP using the NATIVE APPLESCRIPT FUNCTION attached to a button.
 
set film to (choose file with prompt "Choose film.")'s POSIX path
set frame_number to 40
set fps to 25
 
tell application id "com.apple.quicktimeplayer" -- QuickTime Player 7
tell (open film as POSIX file)
set current time to frame_number / fps * time scale
end tell
end tell
 
However I have a field [frame] with a frame as integer and I don't need to select the movie as I have the let (mac_path = Right ( Substitute ( Media Path; "/"; ":"); Length (Media Path) - 1) ;) function to convert the path file from the field in my db
 
I tried to add this portion of the Applescript in my script but the script opens the file and puts the playhead at the beginning of the movie. 
 
This is what I did, but I am not able to make it work. 
 
Let ( 
mac_path = Right ( Substitute ( Media Path; "/"; ":"); Length (Media Path) - 1);
"set frame_number to "  & Frames & ¶ & 
"tell application "Quicktime 7"" & ¶ & 
"activate" & ¶ & 
"open " & Quote ( mac_path ) & ¶ & 
"set current time to frame_number " & ¶ & 
"set the dimensions of movie 1 to {480, 270}" & ¶ & 
"end tell"
)
 
I am aware the script only works if the movie has a timecode track. It won't work otherwise. 
 
Is there a way to fit the "set current time to frame_number " & ¶ & 
of the Applescript in FMP?
 
Thanks and Regards
 
Dan
 

It seems to me that line should be:

 

"set current time to frame_number / 25 * time scale" & ¶ & 

 

To match your working version - otherwise, you are setting the time to a frame number, which isn't going to work well.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.