16 Replies Latest reply: Feb 26, 2008 1:10 AM by prodic RSS

    Bypass "Missing Fonts"-box

    prodic Community Member
      Hi all,

      Here's a weird problem - challenge might be a better word.

      I'm looking for a way to bypass the "Missing Fonts"-dialog when opening an InDesign-file and it has to be done automatically without having to click the OK-button.

      Hoping for a solution. Could be a registry-hack or similar. We're up for anything - almost.

      And yes I'm aware that it's not usually recommended and might cause problems with the font-preview.
      If you need the exact reason for this request let me know.
      It has something to due with changing the links inside the InDesign-file due to a change in our servers file-system.

      Hoping for solution.

      Kenneth
        • 1. Re: Bypass "Missing Fonts"-box
          Community Member
          in Scripting you can use UserInteractionLevel

          which version if ID you use ??

          robin

          --
          www.adobescripts.com
          • 2. Re: Bypass "Missing Fonts"-box
            prodic Community Member
            We're testing this on the CS2-version of Adobe InDesign.

            Will a script provide the necessary solution and could you - or anyone else capable - provide me with an example?

            We might also have to figure out a "auto-click"-solution to the dialog that appears in InDesign CS2 when opening a CS3-document.
            Would a similar script take care of that as well?
            • 3. Re: Bypass "Missing Fonts"-box
              prodic Community Member
              Found a script that's semi-useable.
              However I'm looking for a script/feature/setting that sets "UserInteractionLevel" to never even when opening a file via explorer or via the open-dialog.

              Can that be done?

              //DESCRIPTION: Open Doc with No Warnings

              if (app.version == 3) {
              app.userInteractionLevel = UserInteractionLevels.neverInteract;
              } else {
              app.scriptPreferences.userInteractionLevel = UserInteractionLevels.neverInteract;
              }

              var myFile = File.openDialog("Choose InDesign document to open");
              var myErr = "";
              if (myFile != null) {
              try {
              app.open(myFile);
              } catch (e) {
              myErr = e;
              }
              }
              if (app.version == 3) {
              app.userInteractionLevel = UserInteractionLevels.interactWithAll;
              } else {
              app.scriptPreferences.userInteractionLevel = UserInteractionLevels.interactWithAll;
              }
              if (myErr != "") {
              alert(myErr);
              }
              • 4. Re: Bypass "Missing Fonts"-box
                Harbs. CommunityMVP
                Just run this one-liner before you open your doc:

                app.scriptPreferences.userInteractionLevel = UserInteractionLevels.neverInteract;

                Just make sure you run this one afterwards...

                app.scriptPreferences.userInteractionLevel = UserInteractionLevels.interactWithAll;

                Harbs
                • 5. Re: Bypass "Missing Fonts"-box
                  prodic Community Member
                  Any chance of getting the:

                  app.scriptPreferences.userInteractionLevel = UserInteractionLevels.neverInteract;

                  made a default setting or similar?

                  Imagine you're opening an InDesign-file from a explorer-window/bridge or similar and don't want to see any dialog-screens at all. Is that possible?
                  • 6. Re: Bypass "Missing Fonts"-box
                    Harbs. CommunityMVP
                    Once you set it to never interact, it will stay that way until you set
                    it to interact once more. Be very careful about using never interact
                    though. You might not get dialogs you want...

                    Harbs
                    • 7. Re: Bypass "Missing Fonts"-box
                      prodic Community Member
                      Sadly I can't seem to get the mentioned script to work.

                      Entered the
                      app.scriptPreferences.userInteractionLevel = UserInteractionLevels.neverInteract;
                      in a file and saved it as a .js-file and placed it in the scripting-folder.
                      See the script perfectly fine in InDesign and when I run the script nothing happens - as expected.
                      However when I drag an indd-file from eg. the desk top or a Explorer-window it still prompts me with dialogs(missing fonts etc.)

                      Have I done something wrong? Can't seem to pinpoint the exactly what might have gone wrong and why.

                      Kenneth
                      • 8. Re: Bypass "Missing Fonts"-box
                        Harbs. CommunityMVP
                        What version of InDesign?

                        You can try these instead (but it shouldn't make a difference):
                        app.scriptPreferences.userInteractionLevel
                        =UserInteractionLevels.NEVER_INTERACT;
                        app.scriptPreferences.userInteractionLevel
                        =UserInteractionLevels.INTERACT_WITH_ALL;

                        If the never interact one still doesn't work, you might have something
                        resetting you user interaction level to interact...

                        Try running this script. It'll tell you the current interaction setting...

                        if(app.scriptPreferences.userInteractionLevel
                        ==UserInteractionLevels.NEVER_INTERACT){
                        alert("No Dialogs!");
                        }else{
                        alert("Yes Dialogs!");
                        }

                        Harbs
                        • 9. Re: Bypass "Missing Fonts"-box
                          P Spier CommunityMVP
                          Harbs,

                          I'm pretty ignorant about scripting and the ID object model, but does your script really affect anything beyond user interaction triggered via script?

                          Peter
                          • 10. Re: Bypass "Missing Fonts"-box
                            Harbs. CommunityMVP
                            Peter_Spier@adobeforums.com wrote:
                            > Harbs,
                            >
                            > I'm pretty ignorant about scripting and the ID object model, but does your script really affect anything beyond user interaction triggered via script?
                            >
                            Yes. It affects all dialogs which pop up. (missing fonts, missing links,
                            color setting mismatches, etc.) Try it! ;)

                            Harbs
                            • 11. Re: Bypass "Missing Fonts"-box
                              P Spier CommunityMVP
                              That's OK. I'll take your word for it. I've got enough problems this week without making trouble for myself by screwing up my settings accidentally.
                              • 12. Re: Bypass "Missing Fonts"-box
                                prodic Community Member
                                The version of InDesign is CS2(4.0.5)

                                Made a few sample scripts based on Harbs examples and the results are as follows.

                                When running this script:
                                app.scriptPreferences.userInteractionLevel
                                =UserInteractionLevels.NEVER_INTERACT;
                                the dialog-script displays "No Dialogs" as expected.
                                However when opening a file - with missing fonts - I still get prompted with a missing fonts-dialog.

                                When running this script:
                                app.scriptPreferences.userInteractionLevel
                                =UserInteractionLevels.INTERACT_WITH_ALL;
                                the dialog-script displays "Yes Dialogs" as expected and I get prompted with the missing fonts-dialog.

                                Can't seem to figure out why the "no-script" still displays eg. a missing fonts-dialog.
                                • 13. Re: Bypass "Missing Fonts"-box
                                  Fred Goldman Community Member
                                  I could be wrong, but I always thought the userInteractionLevel
                                  preference was specifically for dialog boxes that appear during scripts.
                                  • 14. Re: Bypass "Missing Fonts"-box
                                    Community Member
                                    Kenneth,

                                    I think, you should use:

                                    app.scriptPreferences.userInteractionLevel = UserInteractionLevels.neverInteract;
                                    app.scriptPreferences.userInteractionLevel = UserInteractionLevels.interactWithAll;

                                    not NEVER_INTERACT and INTERACT_WITH_ALL

                                    robin

                                    --
                                    www.adobescripts.com
                                    • 15. Re: Bypass "Missing Fonts"-box
                                      Community Member
                                      Robin,

                                      Either works. The OMV uses the all caps forms but I prefer the other form.

                                      Dave
                                      • 16. Re: Bypass "Missing Fonts"-box
                                        prodic Community Member
                                        Sadly it didn't make a difference changing it into a non-caps.

                                        Running the script appears to set the setting to "no dialogs" at least the "yes/no-script" provided by Harps displays "no dialogs", so hopefully it's correct.
                                        But when opening an InDesign-file after running the script either through the Open-dialog or via drag from an Explorer-window it still prompts me with missing fonts-dialogs etc.