8 Replies Latest reply on Feb 6, 2017 7:52 AM by schamblee

    Play Video from Local iPad on FMGO.



        Looking for some ideas.

        I have a project that has training videos as part of HR.

        Using Handbrake I have reduced most videos from 200mb to 6-10mb and still be watchable.

        The load times though to iPads that they are doing HR intakes with is still unbearable via LTE network or wifi

      from hosted server.

         (Spec wise: FM 14 Server, FMGO 14 on ipad airs, Verizon LTE and Hotspots)

         So what I am considering doing is storing the videos locally on the ipads then using a script like insert video to load them as globals when server instance starts with ipad.

         One issue I am having is determining exactly where ipads store the videos.... var/private/mobile/Media/iTunes_Control  ??

         And in general is there a better way to do this?

         Any insight or input would be appreciated.

         Also one other question.  They don't employees stopping or fastfowarding the videos (i scripted a button to go to next page of intake that is hidden until the time the video needs to play has passed...) but am wondering if there is a way to completely take away player controls?



        • 1. Re: Play Video from Local iPad on FMGO.

          FMGo has two folder locations Get(TemporaryPath) and Get(DocumentsPath), will have to put your videos in one of these folders. 


          I would suggest using html in a webviewer to play the videos.   Uncheck allow interaction in the webviewer to disable the video controls.


          Sample html to use in a webviewer :  theMovie is a text field containing the path to the video.



          <body style='border=0;overflow:hidden'>
          <body topmargin=0>
          <body leftmargin=0>


          <video width='320' height='240' controls autoplay>
             <source src="& theMovie & " type='video/mp4'>

          Your browser does not support the video tag.



          1 of 1 people found this helpful
          • 2. Re: Play Video from Local iPad on FMGO.

            Ok finally solved this one... and I cannot find anyone who spells this issue out elsewhere so I will try to explain what is going on. (which is strange as I would think this would be common for servers that had video data)


            Client has Server running Filemaker Server.

            Client has 7 Sites total running FM Go and FM Pro.

            Client has a total of 16 copies of FM Go running.

            Weekly they need to run on average about 6 hours of training videos.

            Compressed video using Handbrake to smallest possible (500mb down to 11mb) that was still watchable.

            Due to contract with third party they are supporting they cannot run hardwire landline internet.

            So they have to use LTE.

            This was leading to HIGH bills on overages of data.  (and slow load times)

            So, I needed to load the videos on the iPads so they would be called via script and inserted into containers

            each time FM Go started LOCALLY.


            After hours on the phone with Apple, Apple Dev and Filemaker I realized none of them realized what I was saying, I kept thinking about Samuel L. in Pulp Fiction, English MutherF$@cker do you speak it?


            The issue was not HOW to call the file but how to get Filemaker to find it.


            Solution (level: Simple). You must load videos on to the iOS device via iTunes into the Filemaker App (Like you are adding a database to run locally on your ipad/iphone) and then Filemaker Go can find them.  If you load them as movies, home videos or the like, Filemaker will not find them (at least not easily and not within my limited skill set.)


            Once this is done you can use (as per Schamblee's reply above) the Get(DocumentsPath) function.

            Other wise you will most likely get the NO FILES FOUND type error.


            If you know otherwise, or can prove me to not understand this correctly please advise.  But I will forewarn that the above solution does work and I spent way too many hours banging my head on my keyboard trying to find out WHY???

            • 3. Re: Play Video from Local iPad on FMGO.

              I use dropbox to transfer files to FMGo document folder, it's faster then using iTunes.  

              In dropbox use the send to option then sent to FMGo.


              FMGo 15 added  new feature / icon.  Select the device icon, then the download icon. ( folder with downarrow in upper right hand corner of iPhone), defaults to icloud Drive, select locations to select dropbox, then select the movie or file to download to device.



              Filemaker does not have access to folders outside of itself (referring to local files on the device).  So when you upload as movie on the iDevice using iTuens then FMGo can not read the file from that location.

              • 4. Re: Play Video from Local iPad on FMGO.

                Ok, I appreciate the assistance... But  I am stuck again.  I want you to know I spent about 7 hours so far banging my head against this brick wall before I asked this.


                Filemaker 14 Server.

                FMGo 14 running on iPad.

                Due to client request, need to run video from local iPad not streamed over internet.


                I had issues locating the file.

                I have now found "THE FOLDER" that the video is stored in.

                ( "found" means I can locate the video via filemaker: see above.. )


                My issue now is that when the script below is run no start up (seeding Globals).


                Layout is Training context of the HR Table

                Field is HR::vid_train_forklift

                Video file is c_ppe.m4v (is the m4v required? I tried it both ways to no avail.)


                When the script is called via the Start up script on the ipad...

                I get the following:

                Files on Ipad.PNG

                I have tried several variations on pathname using winfile, file, movie, etc as prefix to variable.

                I then disabled the $var that I was trying to load from and I got the same result.

                So I am thinking that my path is wrong and when it reads my path it just says "Ok, heres the file folder pick the one you want."

                My end goal is to load this as a Global at the start up script WITHOUT dialog.  Without dialog being essential.

                I was able to recreate a similar situation using a button on the layout where the container is to load the file manually.

                (I could use a simple PLAY button and load it then instead of storing a global but I don't see how this changes anything.)  When I did the manual button it loaded up just the c_ppe.m4v file but I still had to select it.


                Can anyone point out where my ignorance lies?

                Appreciate the insight.


                • 5. Re: Play Video from Local iPad on FMGO.

                  Damnit man.

                  I think I solved it... about 20 seconds after I posted this.

                  I looked back at my script for the 500th time and I noticed that the filename I was calling in the variable

                  was c_ppe.m4v and that on the ipad it was c_Ppe.m4v.


                  The difference being the first P not being capitalized.

                  I changed it just to make it match, re-ran the script on the ipad and it loaded without dialog the file into the container from the script...


                  So filemaker is case sensitive on names for file paths???

                  Is it that simple?



                  The working script is here.


                  • 6. Re: Play Video from Local iPad on FMGO.

                    I've seen instances where filenames are case sensitive in FMGo.  

                    2 of 2 people found this helpful
                    • 7. Re: Play Video from Local iPad on FMGO.

                      How have you kept the app from crashing?


                      I have the same project requirements of having to keep media files (images and videos) local on the iPad.


                      Outside of optimizing images as PNG and videos kept as small as possible, have you found any other tips or tricks to keep the app from crashing on iOS?


                      So far I've found that the video will keep "playing" in a PopOver even if the user taps out of it. I have a feeling it is draining the iPad's resources especially when another video is being played in another PopOver, thus leading to an eventual crash.


                      Is the best solution here to just script in the AVplayer steps to automatically pause/stop playback once the user taps out of the video object?


                      Any tips on reducing crashes will be greatly appreciated. In short, should I be focusing in on optimizing and make sure the iPad's resources aren't being used up on non-visible media?

                      • 8. Re: Play Video from Local iPad on FMGO.

                        You may have more control over the video by using a webviewer instead of the AVplayer, in either case I would stop the video before the user changes to another video.