MBS FileMaker Plugin Example Databases

WordFile

All examples are included with download of MBS FileMaker Plugin.

WordFile.fmp12

Overview
Tables1
Relationships0
Layouts1
Scripts2
Value Lists0
Custom Functions0
Custom Menus33
File Options
Default custom menu set[Standard FileMaker Menus]
When opening file
Minimum allowed version12.0
Login usingAccount Name; Account= Admin
Allow user to save passwordOff
Require iOS passcodeOff
Switch to layoutOff
Hide all toolbarsOff
Script triggers
OnFirstWindowOpenScript: Clean
OnLastWindowCloseOff
OnWindowOpenOff
OnWindowCloseOff
OnFileAVPlayerChangeOff
Thumbnail Settings
Generate ThumbnailsOn; Temporary

 

Tables

Table Name
Statistics
Occurrences in Relationship Graph
WordFile
4 fields defined, 9 records
WordFile

Fields

Table Name: WordFile - 4 Fields
Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
InputNormal, BinaryAuto-Enter:
  • Allow editing
Validation:
  • Only during data entry
Storage:
  • Global
  • Repetitions: 1
      PlaceHolderNormal, TextAuto-Enter:
      • Allow editing
      Validation:
      • Only during data entry
      Storage:
      • Repetitions: 1
      • Indexing: None
      • Automatically create indexes as needed
      • Index Language: German
          TextNormal, TextAuto-Enter:
          • Allow editing
          Validation:
          • Only during data entry
          Storage:
          • Repetitions: 1
          • Indexing: None
          • Automatically create indexes as needed
          • Index Language: German
              ResultNormal, TextAuto-Enter:
              • Allow editing
              Validation:
              • Only during data entry
              Storage:
              • Repetitions: 1
              • Indexing: None
              • Automatically create indexes as needed
              • Index Language: German

                  Layout Objects: WordFile

                  Regular Fields

                  Field Name: WordFile::Input
                  Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                  • Top: 6 pt
                  • Left: 138 pt
                  • Bottom: 131 pt
                  • Right: 391 pt
                  • Anchoring: Left, Top
                  Field Format:
                  • Edit Box
                  Field Behavior:
                  • Allow field to be entered: In Find mode, In Browse mode
                  • Touch keyboard type: System Default
                  • Go to next field using: Tab key
                  No

                  Field Name: WordFile::PlaceHolder
                  Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                  • Top: 162 pt
                  • Left: 6 pt
                  • Bottom: 176 pt
                  • Right: 259 pt
                  • Anchoring: Left, Top
                  Field Format:
                  • Edit Box
                  Field Behavior:
                  • Allow field to be entered: In Find mode, In Browse mode
                  • Touch keyboard type: System Default
                  • Go to next field using: Tab key
                  Yes

                  Field Name: WordFile::Text
                  Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                  • Top: 162 pt
                  • Left: 264 pt
                  • Bottom: 176 pt
                  • Right: 517 pt
                  • Anchoring: Left, Top
                  Field Format:
                  • Edit Box
                  Field Behavior:
                  • Allow field to be entered: In Find mode, In Browse mode
                  • Touch keyboard type: System Default
                  • Go to next field using: Tab key
                  Yes

                  Field Name: WordFile::Result
                  Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                  • Top: 162 pt
                  • Left: 522 pt
                  • Bottom: 176 pt
                  • Right: 775 pt
                  • Anchoring: Left, Top
                  Field Format:
                  • Edit Box
                  Field Behavior:
                  • Allow field to be entered: In Find mode, In Browse mode
                  • Touch keyboard type: System Default
                  • Go to next field using: Tab key
                  Yes

                  Group Buttons

                  Button PropertiesCoordinatesScript/Script Step
                    Type:
                  • Text: Run
                    Additional Properties:
                  • Change to hand cursor over button
                  • Rectangular
                  • Top: 102 pt
                  • Left: 408 pt
                  • Bottom: 133 pt
                  • Right: 517 pt
                  • Anchoring: Left, Top
                  Perform Script [ “Run” ]

                  Scripts:


                  Script Hierarchy

                  Run
                  Clean

                  Next Script: [Clean]
                  Script NameRun
                  Run script with full access privilegesOff
                  Include In MenuYes
                  Layouts that use this script
                  Scripts that use this script
                    Script Definition
                    Script Steps
                    • #load from container
                    • Set Variable [ $wordfile; Value:MBS( "WordFile.OpenContainer"; WordFile::Input ) ]
                    • If [ MBS("ISError") ]
                    • Show Custom Dialog [ Title: "Error"; Message: $wordFile; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                    • Exit Script [ ]
                    • End If
                    • #replace placeholders
                    • Go to Record/Request/Page [ First ]
                    • Loop
                    • Set Variable [ $r; Value:MBS( "WordFile.ReplaceTag"; $WordFile; WordFile::PlaceHolder; WordFile::Text) ]
                    • Set Field [ WordFile::Result; $r ]
                    • Commit Records/Requests
                    • Go to Record/Request/Page [ Next; Exit after last ]
                    • End Loop
                    • #write to desktop
                    • Set Variable [ $DesktopPath; Value:MBS("Folders.UserDesktop") ]
                    • Set Variable [ $FilePath; Value:MBS( "Path.AddPathComponent"; $DesktopPath; "test output.docx" ) ]
                    • Set Variable [ $r; Value:MBS( "WordFile.WriteFile"; $WordFile; $FilePath ) ]
                    • Set Variable [ $r; Value:MBS( "Files.LaunchFile"; $FilePath ) ]
                    • #clean up
                    • Set Variable [ $r; Value:MBS("WordFile.Release"; $WordFile) ]
                    Fields used in this script
                    Scripts used in this script
                      Layouts used in this script
                        Tables used in this script
                        Table occurrences used by this script
                        Custom Functions used by this script
                          Custom menu set used by this script

                            Previous Script: [Run]
                            Script NameClean
                            Run script with full access privilegesOff
                            Include In MenuYes
                            Layouts that use this script
                              Scripts that use this script
                                Script Definition
                                Script Steps
                                • Go to Record/Request/Page [ First ]
                                • Loop
                                • Set Field [ WordFile::Result; "" ]
                                • Commit Records/Requests
                                • Go to Record/Request/Page [ Next; Exit after last ]
                                • End Loop
                                Fields used in this script
                                Scripts used in this script
                                  Layouts used in this script
                                    Tables used in this script
                                    Table occurrences used by this script
                                    Custom Functions used by this script
                                      Custom menu set used by this script

                                        Download example: WordFile

                                        Used functions:




                                        Links
                                        MBS Xojo blog