MBS FileMaker Plugin Example Databases

TinyMCE

All examples are included with download of MBS FileMaker Plugin.

TinyMCE.fmp12

Overview
Tables1
Relationships0
Layouts1
Scripts5
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 layoutTinyMCE
Hide all toolbarsOff
Script triggers
OnFirstWindowOpenScript: StartUP
OnLastWindowCloseOff
OnWindowOpenOff
OnWindowCloseOff
OnFileAVPlayerChangeOff
Thumbnail Settings
Generate ThumbnailsOn; Temporary

 

Tables

Table Name
Statistics
Occurrences in Relationship Graph
TinyMCE
2 fields defined, 1 record
TinyMCE

Fields

Table Name: TinyMCE - 2 Fields
Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
TextNormal, TextAuto-Enter:
  • Allow editing
Validation:
  • Only during data entry
Storage:
  • Repetitions: 1
  • Indexing: None
  • Automatically create indexes as needed
  • Index Language: German
      HTMLTextNormal, TextAuto-Enter:
      • Allow editing
      Validation:
      • Only during data entry
      Storage:
      • Repetitions: 1
      • Indexing: None
      • Automatically create indexes as needed
      • Index Language: German

          Layout Objects: TinyMCE

          Regular Fields

          Field Name: TinyMCE::Text
          Field PropertiesCoordinatesField FormatField BehaviorQuick Find
          • Top: 24 pt
          • Left: 66 pt
          • Bottom: 248 pt
          • Right: 403 pt
          • Anchoring: Left, Top
          Field Format:
          • Edit Box
          Field Behavior:
          • Allow field to be entered: In Find mode, In Browse mode
          • Disable visual spell-checking
          • Touch keyboard type: System Default
          • Go to next field using: Tab key
          Yes

          Field Name: TinyMCE::HTMLText
          Field PropertiesCoordinatesField FormatField BehaviorQuick Find
          • Top: 24 pt
          • Left: 480 pt
          • Bottom: 248 pt
          • Right: 841 pt
          • Anchoring: Left, Top
          Field Format:
          • Edit Box
          Field Behavior:
          • Allow field to be entered: In Find mode, In Browse mode
          • Disable visual spell-checking
          • Touch keyboard type: System Default
          • Go to next field using: Tab key
          Yes

          Group Buttons

          Button PropertiesCoordinatesScript/Script Step
            Type:
          • Text: Set
            Additional Properties:
          • Change to hand cursor over button
          • Rounded
          • Top: 255 pt
          • Left: 66 pt
          • Bottom: 280 pt
          • Right: 133 pt
          • Anchoring: Left, Top
          Perform Script [ “Load” ]

          Scripts:


          Button PropertiesCoordinatesScript/Script Step
            Type:
          • Text: Get
            Additional Properties:
          • Change to hand cursor over button
          • Rounded
          • Top: 255 pt
          • Left: 480 pt
          • Bottom: 280 pt
          • Right: 547 pt
          • Anchoring: Left, Top
          Perform Script [ “Save” ]

          Scripts:


          Button PropertiesCoordinatesScript/Script Step
            Type:
          • Text: <<
            Additional Properties:
          • Change to hand cursor over button
          • Rounded
          • Top: 111 pt
          • Left: 420 pt
          • Bottom: 136 pt
          • Right: 463 pt
          • Anchoring: Left, Top
          Set Field [ TinyMCE::Text; TinyMCE::HTMLText ]

          Fields:


          Button PropertiesCoordinatesScript/Script Step
            Type:
          • Text: Show
            Additional Properties:
          • Change to hand cursor over button
          • Rectangular
          • Top: 630 pt
          • Left: 132 pt
          • Bottom: 655 pt
          • Right: 193 pt
          • Anchoring: Left, Top
          Set Variable [ $r; Value:MBS( "WebView.RunJavaScript" ; "HTMLEditor"; "tinyMCE.get('elm1').show();" ) ]

          Button PropertiesCoordinatesScript/Script Step
            Type:
          • Text: Hide
            Additional Properties:
          • Change to hand cursor over button
          • Rectangular
          • Top: 630 pt
          • Left: 66 pt
          • Bottom: 655 pt
          • Right: 127 pt
          • Anchoring: Left, Top
          Set Variable [ $r; Value:MBS( "WebView.RunJavaScript" ; "HTMLEditor"; "tinyMCE.get('elm1').hide();" ) ]

          Web Viewer Controls

          Web Viewer Control PropertiesCoordinatesWeb Address
            Object Name:
          • HTMLEditor
            Additional Properties:
          • Allow interaction with web viewer content
          • Automatically encode URL
          • Top: 288 pt
          • Left: 66 pt
          • Bottom: 613 pt
          • Right: 841 pt
          • Anchoring: Left, Top

          Script Hierarchy

          StartUP
          WebViewer
          Save
          Load
          Reset

          Next Script: [WebViewer]
          Script NameStartUP
          Run script with full access privilegesOff
          Include In MenuYes
          Layouts that use this script
            Scripts that use this script
              Script Definition
              Script Steps
              • #enable debug
              • Set Variable [ $result; Value:MBS("Trace") ]
              • #init webviewer extension
              • If [ Get ( HostApplicationVersion ) = "" /* on server? */ ]
              • #find HTML code
              • Set Variable [ $databasePath; Value:Get(FilePath) ]
              • Set Variable [ $databasePath; Value:MBS("Path.FilemakerPathToNativePath"; $databasePath) ]
              • Set Variable [ $databasePath; Value:Substitute ( $databasePath ; ".fp7" ; ".fmp12") ]
              • Set Variable [ $databaseName; Value:Get(FileName) & ".fmp12" ]
              • Set Variable [ $path; Value:Substitute ( $databasePath ; $databaseName ; "tinymce/index.html" ) ]
              • If [ Get ( SystemPlatform ) = -2 ]
              • Set Variable [ $path; Value:"file://" & Substitute ( $path; "\\" ; "/" ) ]
              • End If
              • Set Web Viewer [ Object Name: "HTMLEditor"; URL: $path ]
              • Else
              • Set Web Viewer [ Object Name: "HTMLEditor"; URL: "http://www.monkeybreadsoftware.de/filemaker/tinymce/index.html" ]
              • End If
              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: [StartUP]Next Script: [Save]
                            Script NameWebViewer
                            Run script with full access privilegesOff
                            Include In MenuYes
                            Layouts that use this script
                              Scripts that use this script
                                Script Definition
                                Script Steps
                                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: [WebViewer]Next Script: [Load]
                                        Script NameSave
                                        Run script with full access privilegesOff
                                        Include In MenuYes
                                        Layouts that use this script
                                        Scripts that use this script
                                          Script Definition
                                          Script Steps
                                          • Set Variable [ $r; Value:MBS( "WebView.RunJavaScript" ; "HTMLEditor"; "try { formtest.output.value = tinyMCE.get('elm1').getContent(); } catch (e) { alert(e); }" ) ]
                                          • Set Field [ TinyMCE::HTMLText; MBS( "WebView.GetFormTextAreaValue" ; "HTMLEditor"; "formtest"; "output"; 0 ) ]
                                          • Set Variable [ $r; Value:MBS( "WebView.RunJavaScript" ; "HTMLEditor"; "window.onbeforeunload = null;") ]
                                          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: [Save]Next Script: [Reset]
                                                  Script NameLoad
                                                  Run script with full access privilegesOff
                                                  Include In MenuYes
                                                  Layouts that use this script
                                                  Scripts that use this script
                                                    Script Definition
                                                    Script Steps
                                                    • Set Variable [ $r; Value:MBS( "WebView.SetFormTextAreaValue" ; "HTMLEditor"; "formtest"; "output"; TinyMCE::Text; 0 ) ]
                                                    • Set Variable [ $r; Value:MBS( "WebView.RunJavaScript" ; "HTMLEditor"; "try { tinyMCE.get('elm1').setContent(formtest.output.value); } catch (e) { alert(e); }" ) ]
                                                    • Set Variable [ $r; Value:MBS( "WebView.RunJavaScript" ; "HTMLEditor"; "window.onbeforeunload = null;") ]
                                                    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: [Load]
                                                            Script NameReset
                                                            Run script with full access privilegesOff
                                                            Include In MenuYes
                                                            Layouts that use this script
                                                              Scripts that use this script
                                                                Script Definition
                                                                Script Steps
                                                                • Set Variable [ $r; Value:MBS( "WebView.RunJavaScript" ; "HTMLEditor"; "window.onbeforeunload = null;") ]
                                                                • Set Web Viewer [ Object Name: "HTMLEditor"; Action: Reset ]
                                                                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: TinyMCE

                                                                              Used functions:




                                                                              Links
                                                                              MBS Xojo PDF Plugins