Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old

MBS FileMaker Plugin Example Databases

Registration

All examples are included with download of MBS FileMaker Plugin.

Registration.fmp12

Overview
Tables1
Relationships0
Layouts1
Scripts6
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
OnFirstWindowOpenOff
OnLastWindowCloseOff
OnWindowOpenOff
OnWindowCloseOff
OnFileAVPlayerChangeOff
Thumbnail Settings
Generate ThumbnailsOn; Temporary

 

Tables

Table Name
Statistics
Occurrences in Relationship Graph
Register
8 fields defined, 1 record
Register

Fields

Table Name: Register - 8 Fields
Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
LicenseeNameNormal, TextAuto-Enter:
  • Allow editing
Validation:
  • Only during data entry
Storage:
  • Repetitions: 1
  • Indexing: None
  • Automatically create indexes as needed
  • Index Language: German
      ComponentNormal, TextAuto-Enter:
      • Allow editing
      Validation:
      • Only during data entry
      Storage:
      • Repetitions: 1
      • Indexing: None
      • Automatically create indexes as needed
      • Index Language: German
          LicenseTypeNormal, TextAuto-Enter:
          • Allow editing
          Validation:
          • Only during data entry
          Storage:
          • Repetitions: 1
          • Indexing: None
          • Automatically create indexes as needed
          • Index Language: German
              ExpireMonthNormal, NumberAuto-Enter:
              • Allow editing
              Validation:
              • Only during data entry
              Storage:
              • Repetitions: 1
              • Indexing: None
              • Automatically create indexes as needed
              • Index Language: German
                  SerialNumberNormal, TextAuto-Enter:
                  • Allow editing
                  Validation:
                  • Only during data entry
                  Storage:
                  • Repetitions: 1
                  • Indexing: None
                  • Automatically create indexes as needed
                  • Index Language: German
                      VersionCalculated, TextCalculation:
                      • Context table: Register
                      • Let([ r = MBS("Version"); r = If( GetAsText ( r ) = "?"; "Not installed"; r) ]; r)
                      Storage:
                      • Repetitions: 1
                      • Do not store calculation results
                      • Index Language: German
                            StateCalculated, TextCalculation:
                            • Context table: Register
                            • Let([ r = MBS( "Plugin.State" ); r = If( GetAsText ( r ) = "?"; "Not installed"; r) ]; r)
                            Storage:
                            • Repetitions: 1
                            • Do not store calculation results
                            • Index Language: German
                                  Compiled DateCalculated, TextCalculation: Storage:
                                  • Repetitions: 1
                                  • Do not store calculation results
                                  • Index Language: German

                                        Layout Objects: Register

                                        Regular Fields

                                        Field Name: Register::LicenseeName
                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                        • Top: 51 pt
                                        • Left: 187 pt
                                        • Bottom: 70 pt
                                        • Right: 475 pt
                                        • Anchoring: Left, Top
                                        Field Format:
                                        • Edit Box
                                        Field Behavior:
                                        • Allow field to be entered: In Find mode, In Browse mode
                                        • Touch keyboard type: Default for Data Type
                                        • Go to next field using: Tab key
                                        Yes

                                        Field Name: Register::Component
                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                        • Top: 74 pt
                                        • Left: 187 pt
                                        • Bottom: 93 pt
                                        • Right: 475 pt
                                        • Anchoring: Left, Top
                                        Field Format:
                                        • Edit Box
                                        Field Behavior:
                                        • Allow field to be entered: In Find mode, In Browse mode
                                        • Touch keyboard type: Default for Data Type
                                        • Go to next field using: Tab key
                                        Yes

                                        Field Name: Register::LicenseType
                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                        • Top: 97 pt
                                        • Left: 187 pt
                                        • Bottom: 116 pt
                                        • Right: 475 pt
                                        • Anchoring: Left, Top
                                        Field Format:
                                        • Edit Box
                                        Field Behavior:
                                        • Allow field to be entered: In Find mode, In Browse mode
                                        • Touch keyboard type: Default for Data Type
                                        • Go to next field using: Tab key
                                        Yes

                                        Field Name: Register::ExpireMonth
                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                        • Top: 120 pt
                                        • Left: 187 pt
                                        • Bottom: 139 pt
                                        • Right: 475 pt
                                        • Anchoring: Left, Top
                                        Field Format:
                                        • Edit Box
                                        Field Behavior:
                                        • Allow field to be entered: In Find mode, In Browse mode
                                        • Touch keyboard type: Default for Data Type
                                        • Go to next field using: Tab key
                                        Yes

                                        Field Name: Register::SerialNumber
                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                        • Top: 143 pt
                                        • Left: 187 pt
                                        • Bottom: 162 pt
                                        • Right: 475 pt
                                        • Anchoring: Left, Top
                                        Field Format:
                                        • Edit Box
                                        Field Behavior:
                                        • Allow field to be entered: In Find mode, In Browse mode
                                        • Touch keyboard type: Default for Data Type
                                        • Go to next field using: Tab key
                                        Yes

                                        Field Name: Register::Version
                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                        • Top: 379 pt
                                        • Left: 485 pt
                                        • Bottom: 398 pt
                                        • Right: 595 pt
                                        • Anchoring: Right, Bottom
                                        Field Format:
                                        • Edit Box
                                        Field Behavior:
                                        • Allow field to be entered: In Find mode, In Browse mode
                                        • Touch keyboard type: Default for Data Type
                                        • Go to next field using: Tab key
                                        Yes

                                        Field Name: Register::State
                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                        • Top: 433 pt
                                        • Left: 485 pt
                                        • Bottom: 452 pt
                                        • Right: 595 pt
                                        • Anchoring: Right, Bottom
                                        Field Format:
                                        • Edit Box
                                        Field Behavior:
                                        • Allow field to be entered: In Find mode, In Browse mode
                                        • Touch keyboard type: Default for Data Type
                                        • Go to next field using: Tab key
                                        Yes

                                        Field Name: Register::Compiled Date
                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                        • Top: 406 pt
                                        • Left: 485 pt
                                        • Bottom: 425 pt
                                        • Right: 595 pt
                                        • Anchoring: Right, Bottom
                                        Field Format:
                                        • Edit Box
                                        Field Behavior:
                                        • Allow field to be entered: In Find mode, In Browse mode
                                        • Touch keyboard type: Default for Data Type
                                        • Go to next field using: Tab key
                                        Yes

                                        Buttons

                                        Button PropertiesCoordinatesScript/Script Step
                                          Type:
                                        • Text: Register
                                        • Top: 235 pt
                                        • Left: 187 pt
                                        • Bottom: 267 pt
                                        • Right: 320 pt
                                        • Anchoring: Left, Top
                                        Perform Script [ “Register” ]

                                        Scripts:


                                        Button PropertiesCoordinatesScript/Script Step
                                          Type:
                                        • Text: Is Registered?
                                        • Top: 180 pt
                                        • Left: 342 pt
                                        • Bottom: 212 pt
                                        • Right: 475 pt
                                        • Anchoring: Left, Top
                                        Perform Script [ “IsRegistered” ]

                                        Scripts:


                                        Button PropertiesCoordinatesScript/Script Step
                                          Type:
                                        • Text: Store Registration
                                        • Top: 307 pt
                                        • Left: 187 pt
                                        • Bottom: 339 pt
                                        • Right: 320 pt
                                        • Anchoring: Left, Top
                                        Perform Script [ “StoreRegistration” ]

                                        Scripts:


                                        Button PropertiesCoordinatesScript/Script Step
                                          Type:
                                        • Text: Clear Registration
                                        • Top: 307 pt
                                        • Left: 342 pt
                                        • Bottom: 339 pt
                                        • Right: 475 pt
                                        • Anchoring: Left, Top
                                        Perform Script [ “ClearRegistration” ]

                                        Scripts:


                                        Button PropertiesCoordinatesScript/Script Step
                                          Type:
                                        • Text: Unregister
                                        • Top: 235 pt
                                        • Left: 342 pt
                                        • Bottom: 267 pt
                                        • Right: 475 pt
                                        • Anchoring: Left, Top
                                        Perform Script [ “Unregister” ]

                                        Scripts:


                                        Script Hierarchy

                                        Register
                                        Unregister
                                        StoreRegistration
                                        ClearRegistration
                                        IsRegistered
                                        Example Register Scirpt

                                        Next Script: [Unregister]
                                        Script NameRegister
                                        Run script with full access privilegesOff
                                        Siri Shortcut VisibleOff
                                        Include In MenuYes
                                        Layouts that use this script
                                        Scripts that use this script
                                          Script Definition
                                          Script Steps
                                          • Set Variable [ $r; Value:MBS( "Register" ;Register::LicenseeName; Register::Component; Register::LicenseType; Register::ExpireMonth; Register::SerialNumber ) ]
                                          • If [ Get ( LastError ) <> 0 ]
                                          • Show Custom Dialog [ Title: "Register"; Message: "Got error code: " & Get ( LastError ); Default Button: “OK”, Commit: “Yes” ]
                                          • Else If [ GetAsText ( $r ) = "?" ]
                                          • Show Custom Dialog [ Title: "Register"; Message: "MBS Plugin not installed"; Default Button: “OK”, Commit: “Yes” ]
                                          • Else
                                          • Show Custom Dialog [ Title: "Register"; Message: $r; Default Button: “OK”, Commit: “Yes” ]
                                          • 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: [Register]Next Script: [StoreRegistration]
                                                  Script NameUnregister
                                                  Run script with full access privilegesOff
                                                  Siri Shortcut VisibleOff
                                                  Include In MenuYes
                                                  Layouts that use this script
                                                  Scripts that use this script
                                                    Script Definition
                                                    Script Steps
                                                    • Set Variable [ $r; Value:MBS( "Unregister" ) ]
                                                    • If [ Get ( LastError ) <> 0 ]
                                                    • Show Custom Dialog [ Title: "Unregister"; Message: "Got error code: " & Get ( LastError ); Default Button: “OK”, Commit: “Yes” ]
                                                    • Else If [ GetAsText ( $r ) = "?" ]
                                                    • Show Custom Dialog [ Title: "Unregister"; Message: "MBS Plugin not installed"; Default Button: “OK”, Commit: “Yes” ]
                                                    • Else
                                                    • Show Custom Dialog [ Title: "Unregister"; Message: $r; Default Button: “OK”, Commit: “Yes” ]
                                                    • 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: [Unregister]Next Script: [ClearRegistration]
                                                                  Script NameStoreRegistration
                                                                  Run script with full access privilegesOff
                                                                  Siri Shortcut VisibleOff
                                                                  Include In MenuYes
                                                                  Layouts that use this script
                                                                  Scripts that use this script
                                                                    Script Definition
                                                                    Script Steps
                                                                    • Set Variable [ $r; Value:MBS( "StoreRegistration" ;Register::LicenseeName; Register::Component; Register::LicenseType; Register::ExpireMonth; Register::SerialNumber ) ]
                                                                    • If [ Get ( LastError ) <> 0 ]
                                                                    • Show Custom Dialog [ Title: "StoreRegistration"; Message: "Got error code: " & Get ( LastError ); Default Button: “OK”, Commit: “Yes” ]
                                                                    • Else If [ GetAsText ( $r ) = "?" ]
                                                                    • Show Custom Dialog [ Title: "StoreRegistration"; Message: "MBS Plugin not installed"; Default Button: “OK”, Commit: “Yes” ]
                                                                    • Else
                                                                    • Show Custom Dialog [ Title: "StoreRegistration"; Message: $r; Default Button: “OK”, Commit: “Yes” ]
                                                                    • 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: [StoreRegistration]Next Script: [IsRegistered]
                                                                            Script NameClearRegistration
                                                                            Run script with full access privilegesOff
                                                                            Siri Shortcut VisibleOff
                                                                            Include In MenuYes
                                                                            Layouts that use this script
                                                                            Scripts that use this script
                                                                              Script Definition
                                                                              Script Steps
                                                                              • Set Variable [ $r; Value:MBS( "ClearRegistration" ;Register::LicenseeName; Register::Component; Register::LicenseType; Register::ExpireMonth; Register::SerialNumber ) ]
                                                                              • If [ Get ( LastError ) <> 0 ]
                                                                              • Show Custom Dialog [ Title: "ClearRegistration"; Message: "Got error code: " & Get ( LastError ); Default Button: “OK”, Commit: “Yes” ]
                                                                              • Else If [ GetAsText ( $r ) = "?" ]
                                                                              • Show Custom Dialog [ Title: "ClearRegistration"; Message: "MBS Plugin not installed"; Default Button: “OK”, Commit: “Yes” ]
                                                                              • Else
                                                                              • Show Custom Dialog [ Title: "ClearRegistration"; Message: $r; Default Button: “OK”, Commit: “Yes” ]
                                                                              • 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: [ClearRegistration]Next Script: [Example Register Scirpt]
                                                                                      Script NameIsRegistered
                                                                                      Run script with full access privilegesOff
                                                                                      Siri Shortcut VisibleOff
                                                                                      Include In MenuYes
                                                                                      Layouts that use this script
                                                                                      Scripts that use this script
                                                                                        Script Definition
                                                                                        Script Steps
                                                                                        • Set Variable [ $r; Value:MBS( "IsRegistered" ) ]
                                                                                        • If [ $r = 1 ]
                                                                                        • Show Custom Dialog [ Title: "Registration"; Message: "The MBS Plugin is registered."; Default Button: “OK”, Commit: “Yes”; Button 2: “Abbrechen”, Commit: “No” ]
                                                                                        • Else
                                                                                        • Show Custom Dialog [ Title: "Registration"; Message: "The MBS Plugin is not registered."; Default Button: “OK”, Commit: “Yes”; Button 2: “Abbrechen”, Commit: “No” ]
                                                                                        • 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: [IsRegistered]
                                                                                                      Script NameExample Register Scirpt
                                                                                                      Run script with full access privilegesOff
                                                                                                      Siri Shortcut VisibleOff
                                                                                                      Include In MenuYes
                                                                                                      Layouts that use this script
                                                                                                        Scripts that use this script
                                                                                                          Script Definition
                                                                                                          Script Steps
                                                                                                          • #Enable debug logging. Shows messages in DebugView/Console.app
                                                                                                          • Set Variable [ $r; Value:MBS("Trace") ]
                                                                                                          • #Register if needed for right platform
                                                                                                          • If [ MBS("IsRegistered") = 0 ]
                                                                                                          • If [ MBS("IsRuntime") ]
                                                                                                          • Set Variable [ $r; Value:MBS("Register"; "test"; "Complete"; "Runtime"; 123; 123) ]
                                                                                                          • Else If [ MBS("IsServer") ]
                                                                                                          • Set Variable [ $r; Value:MBS("Register"; "test"; "Complete"; "Server"; 123; 123) ]
                                                                                                          • Else If [ MBS("IsClient") ]
                                                                                                          • Set Variable [ $r; Value:MBS("Register"; "test"; "Complete"; "5 Seats"; 123; 123) ]
                                                                                                          • Else
                                                                                                          • Set Variable [ $r; Value:"Unknown platform: " & MBS("Platform") ]
                                                                                                          • End If
                                                                                                          • #Show errors, so developer can fix them
                                                                                                          • If [ $r ≠ "OK" ]
                                                                                                          • Show Custom Dialog [ Title: "InitMBS failed."; Message: $r; Default Button: “OK”, Commit: “Yes”; Button 2: “Abbrechen”, Commit: “No” ]
                                                                                                          • End If
                                                                                                          • End If
                                                                                                          • #May initialize other stuff
                                                                                                          • #like dynapdf with library in extensions folder
                                                                                                          • If [ MBS("DynaPDF.IsInitialized") = 0 ]
                                                                                                          • Set Variable [ $DynaPDFLicense; Value:"1003637-16022016-3-8-12-685C57F..." ]
                                                                                                          • If [ MBS("IsWindows") ]
                                                                                                          • Set Variable [ $r; Value:MBS( "DynaPDF.Initialize"; "dynapdf.dll"; $DynaPDFLicense) ]
                                                                                                          • Else If [ MBS("IsMacOSX") ]
                                                                                                          • Set Variable [ $r; Value:MBS( "DynaPDF.Initialize"; "dynapdf.dylib"; $DynaPDFLicense) ]
                                                                                                          • Else
                                                                                                          • Set Variable [ $r; Value:"Unknown platform: " & MBS("Platform") ]
                                                                                                          • End If
                                                                                                          • #Show errors, so developer can fix them
                                                                                                          • If [ $r ≠ "OK" ]
                                                                                                          • Show Custom Dialog [ Title: "InitMBS failed."; Message: $r; Default Button: “OK”, Commit: “Yes”; Button 2: “Abbrechen”, Commit: “No” ]
                                                                                                          • End If
                                                                                                          • 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

                                                                                                                        Download example: Registration

                                                                                                                        Used functions: