6 Replies Latest reply on Apr 15, 2013 6:17 AM by bvondeylen

    Launch App Store from Link

    bvondeylen

      Title

      Launch App Store from Link

      Post

           I created a database to manage apps for our teachers. The submit an app (Copy Link), and the kids are suppose to be able to tap the link and the App Store is suppose to launch.

           Works on the computer. Doesn't on the iPad. Button doesn't do anything.

           Sample Copy Link is https://itunes.apple.com/us/app/agnitus-games-for-learning/id509343934?mt=8

           Since this does not work on the iPad. What does?

        • 1. Re: Launch App Store from Link
          TSGal

               Bryan Von Deylen:

               Thank you for your post.

               I am unable to replicate the issue.  Here are the steps I took:

               1. I created a database file with one text field named "URL".

               2. I created one record and entered in the the URL field: https://itunes.apple.com/us/app/agnitus-games-for-learning/id509343934?mt=8

               3. I created a script "Open URL" with the script step:

               Open URL [ No dialog ; URL ]

               4. I share the file and open it with FileMaker Go on the iPad.

               5. I execute the script, and the iTunes screen appears with the download page.

               Let me know what I'm doing differently than you.

               TSGal
               FileMaker, Inc.

          • 2. Re: Launch App Store from Link
            bvondeylen

                 To get it to work on the computer, I needed to create a script that did this

                 Open URL

                 Substitute ( Location::Link ; "https" ; "itunes" )

                 That way, on the computer it opened inside iTunes and not in Safari.

                 So, taking your cue, I just did a plain Open Url (link) and now in FileMaker GO it works (takes me to the App Store), but when I return to FileMaker GO, I see an error message "Failed to open "<link path here>"  with buttons at the top right to "Open in Safari" and "Done". I press "Done" and it takes me back to the layout I was on. 

                 So, why am I getting this error message when it obviously worked?

            • 3. Re: Launch App Store from Link
              TSGal

                   Bryan Von Deylen:

                   At this point, FileMaker Go is not calling the web kit, as iOS has taken control and opened the App Store.  The error message is an iOS message.

                   One way to get around this is to create a Web Viewer that is equal to the link.  Name the Web Viewer "webviewer" so it can be used with Go to Object. Then, place the Web Viewer off the layout.  Now, use Go to Object script step to access the Web Viewer.  This will launch the App Store, and when you are finished, come back to FileMaker Go.

                   Let me know if you need additional clarification.

                   TSGal
                   FileMaker, Inc.

              • 4. Re: Launch App Store from Link
                bvondeylen

                     OK, not understanding.

                     I created a Web Viewer. In the Inspector > Position, I named it "webviewer'. Placed the Web Viewer container on my layout, but out of view (off to the right).

                     Set the Web Viewer address to be Location::Link (which is the field with the link to the app store).

                     When I click on a field with the script that says Go to Object [Object Name: webviewer], nothing happens at all.

                     If I place the Web Viewer on the layout so I can see it, the Web Viewer portion works. I can see the appropriate web page with the correct app. When viewed by list, all the Web Viewer containers have the appropriate apps in them.

                     So… now what?

                • 5. Re: Launch App Store from Link
                  TSGal

                       Bryan Von Deylen:

                       Although there is a lot of similarity to my first reply, here are the exact steps I took:

                       1. I created a Text field and named it URL.

                       2. I created one record and entered in the the URL field: https://itunes.apple.com/us/app/agnitus-games-for-learning/id509343934?mt=8

                       3. I created a Web Viewer, and for the web address, I specified the URL field.

                       4. With the Web Viewer still highlighted in Layout mode, in the Inspector -> Position -> Name, I entered "WebViewer".

                       5. I placed the Web Viewer off the layout to the right side.

                       6. I saved the Layout and exited to Browse mode.

                       7. I pulled down the Scripts menu and selected "Manage Scripts...".

                       8. I clicked the bottom left icon to create a new script.

                       9. I named the script "Go to Object", and it contained the following script step:

                       Go to Object [ Object Name: "WebViewer" ]

                       10. I saved the script and exited back to Browse Mode.

                       11. I pulled down the File menu and selected Sharing -> FileMaker Network...

                       12. I turned on Network Sharing, selected the currently open file, set network access to All users, and clicked OK.

                       13. On my iPad, I launched FileMaker Go, and opened the shared file.

                       14. I tapped the gear icon in the upper right corner, tapped Perform Script, and tapped the script "Go to Object".

                       At this point, the App Store opens and shows the Agnitus - Games for Learning.  I then close this and return to where I was in FileMaker Go.

                       Let me know what steps you are doing differently.

                       TSGal
                       FileMaker, Inc.

                  • 6. Re: Launch App Store from Link
                    bvondeylen

                         Here are the steps I have. My database is on a FileMaker Pro 12 Server.

                           
                    1.           I have a text field labeled "link", this is where I place my copied link from iTunes.
                    2.      
                    3.           I have a calcuation field labeled 'App Name' which i strip out the App Name from the link.
                    4.      
                    5.           I created a Web Viewer and named it 'url' in Inspector > Position > name
                    6.      
                    7.           Created a script called "Open url" and the only command is "Go to Object [Object name: "url"]
                    8.      
                    9.           Applied that script to the field "App Name" with the Web Viewer off the layout to the right.
                    10.      
                    11.           Set the Web Viewer > Web Address to be Location::Link (the text field with the copied link from iTunes)
                    12.      
                    13.           I left all the default check boxes checked in the Web Viewer
                    14.      
                    15.           Go to Browse mode and click on the field "App Name" and nothing happens.
                    16.      
                    17.           OK, now that I try it again, it is working on the iPad but not on the computer.

                         So it appears to be working now. At this point, I don't care that it wasn't working on Friday, it is working today. Yippee. Thank you