MBS FileMaker Plugin Example Databases

Email Client IMAP

All examples are included with download of MBS FileMaker Plugin.

Email Client IMAP.fmp12

Overview
Tables4
Relationships3
Layouts4
Scripts4
Value Lists1
Custom Functions4
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
EmailClient
15 fields defined, 0 record
EmailClient
Address
4 fields defined, 0 record
Address
Attachment
3 fields defined, 0 record
Attachment
InlineGraphics
3 fields defined, 0 record
InlineGraphics

Fields

Table Name: EmailClient - 15 Fields
Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
ServerNormal, TextAuto-Enter:
  • Allow editing
Validation:
  • Only during data entry
Storage:
  • Global
  • Repetitions: 1
  • Index Language: German
      SubjectNormal, TextAuto-Enter:
      • Allow editing
      Validation:
      • Only during data entry
      Storage:
      • Repetitions: 1
      • Indexing: None
      • Automatically create indexes as needed
      • Index Language: German
          PlainTextNormal, 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
                  MailerNormal, TextAuto-Enter:
                  • Allow editing
                  Validation:
                  • Only during data entry
                  Storage:
                  • Repetitions: 1
                  • Indexing: None
                  • Automatically create indexes as needed
                  • Index Language: German
                      EmailIDNormal, NumberAuto-Enter:
                      • Allow editing
                      • Do not replace existing value for field (if any)
                      • Context table: EmailClient
                        Calculation: Get ( RecordID )
                      Validation:
                      • Only during data entry
                      Storage:
                      • Repetitions: 1
                      • Indexing: All
                      • Index Language: German
                          UsernameNormal, TextAuto-Enter:
                          • Allow editing
                          Validation:
                          • Only during data entry
                          Storage:
                          • Global
                          • Repetitions: 1
                          • Index Language: German
                              PasswordNormal, TextAuto-Enter:
                              • Allow editing
                              Validation:
                              • Only during data entry
                              Storage:
                              • Global
                              • Repetitions: 1
                              • Index Language: German
                                  TypeNormal, TextAuto-Enter:
                                  • Allow editing
                                  Validation: Storage:
                                  • Global
                                  • Repetitions: 1
                                  • Index Language: German
                                          ErrorLogNormal, TextAuto-Enter:
                                          • Allow editing
                                          Validation:
                                          • Only during data entry
                                          Storage:
                                          • Global
                                          • Repetitions: 1
                                          • Index Language: German
                                              MessageIDNormal, TextAuto-Enter:
                                              • Allow editing
                                              Validation:
                                              • Only during data entry
                                              Storage:
                                              • Repetitions: 1
                                              • Indexing: Minimal
                                              • Automatically create indexes as needed
                                              • Index Language: German
                                                  SourceNormal, TextAuto-Enter:
                                                  • Allow editing
                                                  Validation:
                                                  • Only during data entry
                                                  Storage:
                                                  • Repetitions: 1
                                                  • Indexing: None
                                                  • Automatically create indexes as needed
                                                  • Index Language: German
                                                      Source Without AttachmentNormal, TextAuto-Enter:
                                                      • Allow editing
                                                      Validation:
                                                      • Only during data entry
                                                      Storage:
                                                      • Repetitions: 1
                                                      • Indexing: None
                                                      • Automatically create indexes as needed
                                                      • Index Language: German
                                                          DeleteEmailNormal, NumberAuto-Enter:
                                                          • Allow editing
                                                          Validation:
                                                          • Only during data entry
                                                          Storage:
                                                          • Repetitions: 1
                                                          • Indexing: None
                                                          • Automatically create indexes as needed
                                                          • Index Language: German
                                                                HashNormal, TextAuto-Enter:
                                                                • Allow editing
                                                                Validation:
                                                                • Only during data entry
                                                                Storage:
                                                                • Repetitions: 1
                                                                • Indexing: Minimal
                                                                • Automatically create indexes as needed
                                                                • Index Language: German

                                                                    Table Name: Address - 4 Fields
                                                                    Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
                                                                    TypeNormal, TextAuto-Enter:
                                                                    • Allow editing
                                                                    Validation:
                                                                    • Only during data entry
                                                                    Storage:
                                                                    • Repetitions: 1
                                                                    • Indexing: None
                                                                    • Automatically create indexes as needed
                                                                    • Index Language: German
                                                                        NameNormal, TextAuto-Enter:
                                                                        • Allow editing
                                                                        Validation:
                                                                        • Only during data entry
                                                                        Storage:
                                                                        • Repetitions: 1
                                                                        • Indexing: None
                                                                        • Automatically create indexes as needed
                                                                        • Index Language: German
                                                                            EmailNormal, TextAuto-Enter:
                                                                            • Allow editing
                                                                            Validation:
                                                                            • Only during data entry
                                                                            Storage:
                                                                            • Repetitions: 1
                                                                            • Indexing: None
                                                                            • Automatically create indexes as needed
                                                                            • Index Language: German
                                                                                EmailIDNormal, NumberAuto-Enter:
                                                                                • Allow editing
                                                                                Validation:
                                                                                • Only during data entry
                                                                                Storage:
                                                                                • Repetitions: 1
                                                                                • Indexing: All
                                                                                • Index Language: German

                                                                                    Table Name: Attachment - 3 Fields
                                                                                    Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
                                                                                    EmailIDNormal, NumberAuto-Enter:
                                                                                    • Allow editing
                                                                                    Validation:
                                                                                    • Only during data entry
                                                                                    Storage:
                                                                                    • Repetitions: 1
                                                                                    • Indexing: All
                                                                                    • Index Language: German
                                                                                      ContentNormal, BinaryAuto-Enter:
                                                                                      • Allow editing
                                                                                      Validation:
                                                                                      • Only during data entry
                                                                                      Storage:
                                                                                      • Repetitions: 1
                                                                                          FileNameNormal, TextAuto-Enter:
                                                                                          • Allow editing
                                                                                          Validation:
                                                                                          • Only during data entry
                                                                                          Storage:
                                                                                          • Repetitions: 1
                                                                                          • Indexing: None
                                                                                          • Automatically create indexes as needed
                                                                                          • Index Language: German

                                                                                              Table Name: InlineGraphics - 3 Fields
                                                                                              Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
                                                                                              EmailIDNormal, NumberAuto-Enter:
                                                                                              • Allow editing
                                                                                              Validation:
                                                                                              • Only during data entry
                                                                                              Storage:
                                                                                              • Repetitions: 1
                                                                                              • Indexing: All
                                                                                              • Index Language: German
                                                                                                ContentNormal, BinaryAuto-Enter:
                                                                                                • Allow editing
                                                                                                Validation:
                                                                                                • Only during data entry
                                                                                                Storage:
                                                                                                • Repetitions: 1
                                                                                                    FileNameNormal, TextAuto-Enter:
                                                                                                    • Allow editing
                                                                                                    Validation:
                                                                                                    • Only during data entry
                                                                                                    Storage:
                                                                                                    • Repetitions: 1
                                                                                                    • Indexing: None
                                                                                                    • Automatically create indexes as needed
                                                                                                    • Index Language: German

                                                                                                        Relationship: EmailClient=Address

                                                                                                        Table OccurrenceEmailClientAddress
                                                                                                        FieldEmailID=EmailID
                                                                                                        Source TableEmailClientAddress
                                                                                                        Source FileEmail Client IMAP.fmp12Email Client IMAP.fmp12
                                                                                                        Allow creation of records via this relationshipOffOff
                                                                                                        Delete related records in this table when a record is deleted in the other tableOffOff
                                                                                                        Sort records

                                                                                                        Off

                                                                                                        Off

                                                                                                        Relationship: EmailClient=InlineGraphics

                                                                                                        Table OccurrenceEmailClientInlineGraphics
                                                                                                        FieldEmailID=EmailID
                                                                                                        Source TableEmailClientInlineGraphics
                                                                                                        Source FileEmail Client IMAP.fmp12Email Client IMAP.fmp12
                                                                                                        Allow creation of records via this relationshipOffOff
                                                                                                        Delete related records in this table when a record is deleted in the other tableOffOff
                                                                                                        Sort records

                                                                                                        Off

                                                                                                        Off

                                                                                                        Layouts

                                                                                                        Layout Hierarchy

                                                                                                        EmailClient
                                                                                                        Address
                                                                                                        Attachment
                                                                                                        InlineGraphics


                                                                                                        Layout NameInclude In MenuQuick Find# of ObjectsShow Records FromSave record changes automaticallyShow field frames when record is activeShow field frames only on current recordShow current record indicator in List ViewUsed in ScriptsCustom Menu SetScript TriggersTheme ID
                                                                                                        EmailClientYesYes EmailClientOnOnOffOn [File Default]01
                                                                                                        AddressYesYes AddressOnOnOffOn [File Default]01
                                                                                                        AttachmentYesYes AttachmentOnOnOffOn [File Default]01
                                                                                                        InlineGraphicsYesYes InlineGraphicsOnOnOffOn [File Default]01

                                                                                                        Layout Objects: EmailClient

                                                                                                        Regular Fields

                                                                                                        Field Name: EmailClient::Server
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 6 pt
                                                                                                        • Left: 132 pt
                                                                                                        • Bottom: 20 pt
                                                                                                        • Right: 385 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: EmailClient::Subject
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 84 pt
                                                                                                        • Left: 132 pt
                                                                                                        • Bottom: 98 pt
                                                                                                        • Right: 385 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: EmailClient::PlainText
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 126 pt
                                                                                                        • Left: 132 pt
                                                                                                        • Bottom: 272 pt
                                                                                                        • Right: 481 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: EmailClient::HTMLText
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 126 pt
                                                                                                        • Left: 486 pt
                                                                                                        • Bottom: 272 pt
                                                                                                        • Right: 835 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: EmailClient::Mailer
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 102 pt
                                                                                                        • Left: 132 pt
                                                                                                        • Bottom: 116 pt
                                                                                                        • Right: 385 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: Address::Type
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 278 pt
                                                                                                        • Left: 13 pt
                                                                                                        • Bottom: 293 pt
                                                                                                        • Right: 192 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: Address::Name
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 278 pt
                                                                                                        • Left: 193 pt
                                                                                                        • Bottom: 293 pt
                                                                                                        • Right: 372 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: Address::Email
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 278 pt
                                                                                                        • Left: 373 pt
                                                                                                        • Bottom: 293 pt
                                                                                                        • Right: 551 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: Attachment::Content
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 403 pt
                                                                                                        • Left: 13 pt
                                                                                                        • Bottom: 419 pt
                                                                                                        • Right: 144 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: Attachment::FileName
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 403 pt
                                                                                                        • Left: 145 pt
                                                                                                        • Bottom: 419 pt
                                                                                                        • Right: 275 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: InlineGraphics::Content
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 403 pt
                                                                                                        • Left: 283 pt
                                                                                                        • Bottom: 419 pt
                                                                                                        • Right: 417 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: InlineGraphics::FileName
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 403 pt
                                                                                                        • Left: 418 pt
                                                                                                        • Bottom: 419 pt
                                                                                                        • Right: 551 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: EmailClient::EmailID
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 84 pt
                                                                                                        • Left: 780 pt
                                                                                                        • Bottom: 98 pt
                                                                                                        • Right: 835 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: EmailClient::Username
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 24 pt
                                                                                                        • Left: 132 pt
                                                                                                        • Bottom: 38 pt
                                                                                                        • Right: 385 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: EmailClient::Password
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 42 pt
                                                                                                        • Left: 132 pt
                                                                                                        • Bottom: 56 pt
                                                                                                        • Right: 385 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: EmailClient::ErrorLog
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 6 pt
                                                                                                        • Left: 708 pt
                                                                                                        • Bottom: 74 pt
                                                                                                        • Right: 961 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: EmailClient::MessageID
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 534 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 548 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
                                                                                                        Yes

                                                                                                        Field Name: EmailClient::Source
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 552 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 734 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
                                                                                                        Yes

                                                                                                        Field Name: EmailClient::Source Without Attachment
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 552 pt
                                                                                                        • Left: 552 pt
                                                                                                        • Bottom: 733 pt
                                                                                                        • Right: 805 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: EmailClient::DeleteEmail
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 738 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 752 pt
                                                                                                        • Right: 217 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: EmailClient::Hash
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 534 pt
                                                                                                        • Left: 438 pt
                                                                                                        • Bottom: 548 pt
                                                                                                        • Right: 691 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: Download emails
                                                                                                          Additional Properties:
                                                                                                        • Change to hand cursor over button
                                                                                                        • Rectangular
                                                                                                        • Top: 48 pt
                                                                                                        • Left: 402 pt
                                                                                                        • Bottom: 73 pt
                                                                                                        • Right: 529 pt
                                                                                                        • Anchoring: Left, Top
                                                                                                        Perform Script [ “GetEmails” ]

                                                                                                        Scripts:


                                                                                                        Portals

                                                                                                        Portal PropertiesCoordinatesFieldsOptions
                                                                                                        • Top: 276 pt
                                                                                                        • Left: 12 pt
                                                                                                        • Bottom: 397 pt
                                                                                                        • Right: 553 pt
                                                                                                        • Anchoring: Left, Top
                                                                                                        Field Objects
                                                                                                        • Sort records: Off
                                                                                                        • Filter calculation: None
                                                                                                        • Initial Row: 1
                                                                                                        • Number of Rows: 7

                                                                                                        Portal PropertiesCoordinatesFieldsOptions
                                                                                                        • Top: 402 pt
                                                                                                        • Left: 12 pt
                                                                                                        • Bottom: 529 pt
                                                                                                        • Right: 277 pt
                                                                                                        • Anchoring: Left, Top
                                                                                                        Field Objects
                                                                                                        • Sort records: Off
                                                                                                        • Filter calculation: None
                                                                                                        • Initial Row: 1
                                                                                                        • Number of Rows: 7

                                                                                                        Portal PropertiesCoordinatesFieldsOptions
                                                                                                        • Top: 402 pt
                                                                                                        • Left: 282 pt
                                                                                                        • Bottom: 529 pt
                                                                                                        • Right: 553 pt
                                                                                                        • Anchoring: Left, Top
                                                                                                        Field Objects
                                                                                                        • Sort records: Off
                                                                                                        • Filter calculation: None
                                                                                                        • Initial Row: 1
                                                                                                        • Number of Rows: 7

                                                                                                        Layout Objects: Address

                                                                                                        Regular Fields

                                                                                                        Field Name: Address::Type
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 24 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 38 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
                                                                                                        Yes

                                                                                                        Field Name: Address::Name
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 42 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 56 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
                                                                                                        Yes

                                                                                                        Field Name: Address::Email
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 60 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 74 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
                                                                                                        Yes

                                                                                                        Layout Objects: Attachment

                                                                                                        Regular Fields

                                                                                                        Field Name: Attachment::EmailID
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 24 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 38 pt
                                                                                                        • Right: 217 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: Attachment::Content
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 42 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 167 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: Attachment::FileName
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 168 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 182 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
                                                                                                        Yes

                                                                                                        Layout Objects: InlineGraphics

                                                                                                        Regular Fields

                                                                                                        Field Name: InlineGraphics::EmailID
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 24 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 38 pt
                                                                                                        • Right: 217 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: InlineGraphics::Content
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 42 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 167 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: InlineGraphics::FileName
                                                                                                        Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                                                                                                        • Top: 168 pt
                                                                                                        • Left: 138 pt
                                                                                                        • Bottom: 182 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
                                                                                                        Yes

                                                                                                        Value Lists

                                                                                                        Value List NameSourceValuesOn Layouts
                                                                                                        EmailServerTypeCustom
                                                                                                        • POP3, IMAP

                                                                                                          Script Hierarchy

                                                                                                          ClearAll
                                                                                                          GetEmails
                                                                                                          Hide ProgressDialog
                                                                                                          ParseEmail

                                                                                                          Next Script: [GetEmails]
                                                                                                          Script NameClearAll
                                                                                                          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 Layout [ “EmailClient” (EmailClient) ]
                                                                                                              • Delete All Records [ No dialog ]
                                                                                                              • Go to Layout [ “Address” (Address) ]
                                                                                                              • Delete All Records [ No dialog ]
                                                                                                              • Go to Layout [ “Attachment” (Attachment) ]
                                                                                                              • Delete All Records [ No dialog ]
                                                                                                              • Go to Layout [ “InlineGraphics” (InlineGraphics) ]
                                                                                                              • Delete All Records [ No dialog ]
                                                                                                              • Go to Layout [ original layout ]
                                                                                                              • Set Field [ EmailClient::ErrorLog; "" ]
                                                                                                              • Commit Records/Requests
                                                                                                              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: [ClearAll]Next Script: [Hide ProgressDialog]
                                                                                                                    Script NameGetEmails
                                                                                                                    Run script with full access privilegesOff
                                                                                                                    Include In MenuYes
                                                                                                                    Layouts that use this script
                                                                                                                    Scripts that use this script
                                                                                                                      Script Definition
                                                                                                                      Script Steps
                                                                                                                      • # get URL
                                                                                                                      • Set Variable [ $URL; Value:"imap://" & EmailClient::Server & "/INBOX" ]
                                                                                                                      • Set Variable [ $NeedPurge; Value:0 ]
                                                                                                                      • # show progress
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.SetTopText"; "Get Email") ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.SetBottomText"; "List emails...") ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.SetProgress"; -1) ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.SetButtonCaption"; "Cancel") ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.Show") ]
                                                                                                                      • # query list of emails
                                                                                                                      • Set Variable [ $curl; Value:MBS("CURL.New") ]
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionURL"; $curl; $URL) ]
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionUserName"; $curl; EmailClient::Username) ]
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionPassword"; $curl; EmailClient::Password) ]
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionCustomRequest"; $curl; "FETCH 1:* (FLAGS BODY[HEADER.FIELDS (Message-Id)])") ]
                                                                                                                      • Set Variable [ $result; Value:MBS("CURL.Perform"; $curl) ]
                                                                                                                      • Set Variable [ $output; Value:MBS("CURL.GetResultAsText"; $curl) ]
                                                                                                                      • Set Variable [ $debug; Value:MBS("CURL.GetDebugAsText"; $curl) ]
                                                                                                                      • Set Field [ EmailClient::ErrorLog; $debug ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.Update") ]
                                                                                                                      • If [ GetAsNumber($result) = 21 ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.Hide") ]
                                                                                                                      • Show Custom Dialog [ Title: "No emails"; Message: "Sorry, no emails. See error log field for details."; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                                                                                                      • Else If [ $result ≠ "OK" ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.Hide") ]
                                                                                                                      • Show Custom Dialog [ Title: "Failed to get emails"; Message: "See error log field for details."; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                                                                                                      • Else
                                                                                                                      • Set Variable [ $EmailCount; Value:ValueCount ( $output ) ]
                                                                                                                      • Set Variable [ $EmailIndex; Value:1 ]
                                                                                                                      • Loop
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.SetProgress";100 * $EmailIndex / ($EmailCount-1) ) ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.SetBottomText"; "Get Email " & ($EmailIndex) & " of " & ($EmailCount) ) ]
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.Update") ]
                                                                                                                      • # get emails
                                                                                                                      • Set Variable [ $Line; Value:GetValue ( $output ; $EmailIndex ) ]
                                                                                                                      • #check the line number
                                                                                                                      • Set Variable [ $LineNo; Value:ValueOffsetInList($debug; 1; $Line) ]
                                                                                                                      • #find the line with message id
                                                                                                                      • Set Variable [ $MLine; Value:GetValue ( $debug ; $LineNo + 1 ) ]
                                                                                                                      • #now check if it starts with message-id
                                                                                                                      • Set Variable [ $MessageIDLabel; Value:Left ( $MLine ; 12 ) ]
                                                                                                                      • Set Variable [ $$MesageID; Value:Middle ( $MLine ; 13; Length($MLine) ) ]
                                                                                                                      • If [ $MessageIDLabel ≠ "Message-Id: " ]
                                                                                                                      • #no message ID?
                                                                                                                      • Set Variable [ $$MesageID; Value:"" ]
                                                                                                                      • End If
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionCustomRequest"; $curl; "") ]
                                                                                                                      • Set Variable [ $EmailID; Value:GetValue(Substitute($Line; " "; ¶); 2) ]
                                                                                                                      • #Do we have it?
                                                                                                                      • Set Variable [ $found; Value:MBS("FM.ExecuteSQL"; "SELECT count(*) from EmailClient where MessageID = '"& $$MesageID & "'") ]
                                                                                                                      • If [ $found = 1 ]
                                                                                                                      • #Should be deleted?
                                                                                                                      • Set Variable [ $deleted; Value:MBS("FM.ExecuteSQL"; "SELECT DeleteEmail from EmailClient where MessageID = '"& $$MesageID & "'") ]
                                                                                                                      • If [ $deleted = 1 ]
                                                                                                                      • #Delete Email:
                                                                                                                      • Set Variable [ $URL; Value:"imap://" & EmailClient::Server & "/INBOX" ]
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionURL"; $curl; $URL) ]
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionCustomRequest"; $curl; "STORE " & $EmailID & " +FLAGS (\DELETED)") ]
                                                                                                                      • Set Variable [ $result; Value:MBS("CURL.Perform"; $curl) ]
                                                                                                                      • Set Field [ EmailClient::ErrorLog; MBS("CURL.GetDebugAsText"; $curl) ]
                                                                                                                      • If [ $result ≠ "OK" ]
                                                                                                                      • Show Custom Dialog [ Title: "Failed to mark email as deleted."; Message: "See error log field for details."; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                                                                                                      • Exit Loop If [ 1 ]
                                                                                                                      • Else
                                                                                                                      • Set Variable [ $NeedPurge; Value:1 ]
                                                                                                                      • End If
                                                                                                                      • End If
                                                                                                                      • Else If [ $found = 0 ]
                                                                                                                      • #it is a new email
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionURL"; $curl; $URL & ";UID=" & $EmailID) ]
                                                                                                                      • If [ $EmailID ≠ "" ]
                                                                                                                      • // Set Variable [ $r; Value:MBS("Log"; "EmailID: "; $EmailID) ]
                                                                                                                      • # get an email
                                                                                                                      • Set Variable [ $result; Value:MBS("CURL.Perform"; $curl) ]
                                                                                                                      • Set Field [ EmailClient::ErrorLog; MBS("CURL.GetDebugAsText"; $curl) ]
                                                                                                                      • If [ $result ≠ "OK" ]
                                                                                                                      • Show Custom Dialog [ Title: "Failed to load an email."; Message: "See error log field for details."; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                                                                                                      • Exit Loop If [ 1 ]
                                                                                                                      • Else
                                                                                                                      • # parse email
                                                                                                                      • Set Variable [ $EmailRef; Value:MBS("CURL.GetResultAsEmail"; $curl) ]
                                                                                                                      • If [ MBS("IsError") ]
                                                                                                                      • Show Custom Dialog [ Title: "Failed to get an email."; Message: "See error log field for details."; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                                                                                                      • Exit Loop If [ 1 ]
                                                                                                                      • Else
                                                                                                                      • Perform Script [ “ParseEmail”; Parameter: $EmailRef ]
                                                                                                                      • End If
                                                                                                                      • End If
                                                                                                                      • End If
                                                                                                                      • End If
                                                                                                                      • # next
                                                                                                                      • Set Variable [ $EmailIndex; Value:$EmailIndex + 1 ]
                                                                                                                      • Exit Loop If [ $EmailIndex > $EmailCount ]
                                                                                                                      • Exit Loop If [ MBS("ProgressDialog.GetCancel") ]
                                                                                                                      • End Loop
                                                                                                                      • End If
                                                                                                                      • Set Variable [ $r; Value:MBS("ProgressDialog.Hide") ]
                                                                                                                      • #purge
                                                                                                                      • If [ $NeedPurge = 1 ]
                                                                                                                      • Set Variable [ $URL; Value:"imap://" & EmailClient::Server & "/INBOX" ]
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionURL"; $curl; $URL) ]
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.SetOptionCustomRequest"; $curl; "EXPUNGE") ]
                                                                                                                      • Set Variable [ $result; Value:MBS("CURL.Perform"; $curl) ]
                                                                                                                      • Set Field [ EmailClient::ErrorLog; MBS("CURL.GetDebugAsText"; $curl) ]
                                                                                                                      • If [ $result ≠ "OK" ]
                                                                                                                      • Show Custom Dialog [ Title: "Failed to delete emails."; Message: "See error log field for details."; Default Button: “OK”, Commit: “Yes”; Button 2: “Cancel”, Commit: “No” ]
                                                                                                                      • End If
                                                                                                                      • End If
                                                                                                                      • Set Variable [ $r; Value:MBS("CURL.Cleanup"; $curl) ]
                                                                                                                      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: [GetEmails]Next Script: [ParseEmail]
                                                                                                                          Script NameHide ProgressDialog
                                                                                                                          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: [Hide ProgressDialog]
                                                                                                                                            Script NameParseEmail
                                                                                                                                            Run script with full access privilegesOff
                                                                                                                                            Include In MenuNo
                                                                                                                                            Layouts that use this script
                                                                                                                                              Scripts that use this script
                                                                                                                                              Script Definition
                                                                                                                                              Script Steps
                                                                                                                                              • Set Variable [ $email; Value:Get(ScriptParameter) ]
                                                                                                                                              • Set Variable [ $Hash; Value:MBS( "EmailParser.Hash"; $email ) ]
                                                                                                                                              • Set Variable [ $found; Value:MBS("FM.ExecuteSQL"; "SELECT count(*) from EmailClient where Hash = '"& $Hash & "'") ]
                                                                                                                                              • If [ $found = 0 ]
                                                                                                                                              • Go to Layout [ “EmailClient” (EmailClient) ]
                                                                                                                                              • #Show text:
                                                                                                                                              • New Record/Request
                                                                                                                                              • Set Field [ EmailClient::Source; MBS("EmailParser.Source"; $email) ]
                                                                                                                                              • Set Field [ EmailClient::Source Without Attachment; MBS("EmailParser.SourceWithoutAttachments"; $email) ]
                                                                                                                                              • Set Field [ EmailClient::Subject; MBS("EmailParser.Subject"; $email) ]
                                                                                                                                              • Set Field [ EmailClient::PlainText; MBS("EmailParser.plainText"; $email) ]
                                                                                                                                              • Set Field [ EmailClient::HTMLText; MBS("EmailParser.HTMLText"; $email) ]
                                                                                                                                              • Set Field [ EmailClient::MessageID; $$MesageID ]
                                                                                                                                              • Set Field [ EmailClient::Hash; $Hash ]
                                                                                                                                              • Commit Records/Requests [ Skip data entry validation; No dialog ]
                                                                                                                                              • #find all addresses
                                                                                                                                              • Set Variable [ $EmailRecordID; Value:Get(RecordID) ]
                                                                                                                                              • Set Variable [ $i; Value:0 ]
                                                                                                                                              • Set Variable [ $c; Value:MBS("EmailParser.AddressCount"; $email) ]
                                                                                                                                              • If [ $c > 0 ]
                                                                                                                                              • Go to Related Record [ From table: “Address”; Using layout: “Address” (Address) ] [ Show only related records ]
                                                                                                                                              • Go to Layout [ “Address” (Address) ]
                                                                                                                                              • Loop
                                                                                                                                              • Set Variable [ $Name; Value:MBS("EmailParser.Address"; $email; $i; "name") ]
                                                                                                                                              • Set Variable [ $emailAddress; Value:MBS("EmailParser.Address"; $email; $i; "email") ]
                                                                                                                                              • Set Variable [ $type; Value:MBS("EmailParser.Address"; $email; $i; "type") ]
                                                                                                                                              • New Record/Request
                                                                                                                                              • Set Field [ Address::Type; $type ]
                                                                                                                                              • Set Field [ Address::Email; $emailAddress ]
                                                                                                                                              • Set Field [ Address::Name; $name ]
                                                                                                                                              • Set Field [ Address::EmailID; $EmailRecordID ]
                                                                                                                                              • Commit Records/Requests [ Skip data entry validation; No dialog ]
                                                                                                                                              • #next
                                                                                                                                              • Set Variable [ $i; Value:$i + 1 ]
                                                                                                                                              • Exit Loop If [ $i = $c ]
                                                                                                                                              • End Loop
                                                                                                                                              • End If
                                                                                                                                              • #find all attachments
                                                                                                                                              • Set Variable [ $i; Value:0 ]
                                                                                                                                              • Set Variable [ $c; Value:MBS("EmailParser.AttachmentCount"; $email) ]
                                                                                                                                              • If [ $c > 0 ]
                                                                                                                                              • Go to Related Record [ From table: “Attachment”; Using layout: “Attachment” (Attachment) ] [ Show only related records ]
                                                                                                                                              • Go to Layout [ “Attachment” (Attachment) ]
                                                                                                                                              • Loop
                                                                                                                                              • Set Variable [ $Name; Value:MBS("EmailParser.attachment"; $email; $i; "filename") ]
                                                                                                                                              • Set Variable [ $content; Value:MBS("EmailParser.attachment"; $email; $i; "container") ]
                                                                                                                                              • New Record/Request
                                                                                                                                              • Set Field [ Attachment::Content; $content ]
                                                                                                                                              • Set Field [ Attachment::FileName; $name ]
                                                                                                                                              • Set Field [ Attachment::EmailID; $EmailRecordID ]
                                                                                                                                              • Commit Records/Requests [ Skip data entry validation; No dialog ]
                                                                                                                                              • #next
                                                                                                                                              • Set Variable [ $i; Value:$i + 1 ]
                                                                                                                                              • Exit Loop If [ $i = $c ]
                                                                                                                                              • End Loop
                                                                                                                                              • End If
                                                                                                                                              • #find all inline graphics
                                                                                                                                              • Set Variable [ $i; Value:0 ]
                                                                                                                                              • Set Variable [ $c; Value:MBS("EmailParser.InlineCount"; $email) ]
                                                                                                                                              • If [ $c > 0 ]
                                                                                                                                              • Go to Related Record [ From table: “InlineGraphics”; Using layout: “InlineGraphics” (InlineGraphics) ] [ Show only related records ]
                                                                                                                                              • Go to Layout [ “InlineGraphics” (InlineGraphics) ]
                                                                                                                                              • Loop
                                                                                                                                              • Set Variable [ $Name; Value:MBS("EmailParser.inline"; $email; $i; "filename") ]
                                                                                                                                              • Set Variable [ $content; Value:MBS("EmailParser.Inline"; $email; $i; "container") ]
                                                                                                                                              • New Record/Request
                                                                                                                                              • Set Field [ InlineGraphics::Content; $content ]
                                                                                                                                              • Set Field [ InlineGraphics::FileName; $name ]
                                                                                                                                              • Set Field [ InlineGraphics::EmailID; $EmailRecordID ]
                                                                                                                                              • Commit Records/Requests [ Skip data entry validation; No dialog ]
                                                                                                                                              • #next
                                                                                                                                              • Set Variable [ $i; Value:$i + 1 ]
                                                                                                                                              • Exit Loop If [ $i = $c ]
                                                                                                                                              • End Loop
                                                                                                                                              • End If
                                                                                                                                              • Go to Layout [ original layout ]
                                                                                                                                              • #find a header
                                                                                                                                              • Set Variable [ $i; Value:0 ]
                                                                                                                                              • Set Variable [ $c; Value:MBS("EmailParser.HeaderCount"; $email) ]
                                                                                                                                              • If [ $c > 0 ]
                                                                                                                                              • Loop
                                                                                                                                              • Set Variable [ $HeaderName; Value:MBS("EmailParser.Header"; $email; $i; "name") ]
                                                                                                                                              • If [ $HeaderName = "X-Mailer" ]
                                                                                                                                              • Set Variable [ $HeaderValue; Value:MBS("EmailParser.Header"; $email; $i; "value") ]
                                                                                                                                              • Set Field [ EmailClient::Mailer; $HeaderValue ]
                                                                                                                                              • End If
                                                                                                                                              • #next
                                                                                                                                              • Set Variable [ $i; Value:$i + 1 ]
                                                                                                                                              • Exit Loop If [ $i = $c ]
                                                                                                                                              • End Loop
                                                                                                                                              • End If
                                                                                                                                              • End If
                                                                                                                                              • #cleanup
                                                                                                                                              • Set Variable [ $r; Value:MBS("EmailParser.Free"; $email) ]
                                                                                                                                              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

                                                                                                                                                    Custom Functions

                                                                                                                                                    Function NameParametersAvailabilityDefinitionIn Field DefinitionsIn Scripts
                                                                                                                                                    ValueOffsetInListlistToSearch;startIndex;valueAll accountsIf ( ValueCount ( listToSearch ) < 1 ; 0 ; If ( startIndex > ValueCount ( listToSearch ) ; 0 ; If ( GetValue ( listToSearch ; startIndex ) = value ; startIndex ; ValueOffsetInList ( listToSearch ; startIndex + 1 ; value ) ) ) )
                                                                                                                                                      ParseAllBetweensource;start;stop;startPos;resultAll accountsLet ([ first = Position ( source; start; startPos; 1 ); firstPos = first + Length(start); end = Position ( source; stop; firstPos; 1 ); chars = end - firstPos ]; If ( first ≠ 0; ParseAllBetween( source; start; stop; end + Length ( stop); List ( result ; Middle ( source ; firstPos ; chars))); result ) )
                                                                                                                                                        AddPrefixSuffixToList#_liste;#_prefix;#_suffixAll accounts// Description: // AddPrefixSuffixToList ( theList ; prefix ; suffix ) // A recursive function that takes a list of values and adds a prefix and suffix // Written by Andy Knasinski // www.nrgsoft.com // sample // AddPrefixSuffixToList ( "value1¶value2" ; "<value>" ; "</value>" ) // would return an XML string for all values in a field If ( IsEmpty ( #_liste ); #_liste ; Let ( aValue = GetValue ( #_liste ; 1 ) ; #_prefix & aValue & #_suffix & If ( ValueCount ( #_liste ) > 1 ; "¶" ; "" ) & AddPrefixSuffixToList ( RightValues ( #_liste ; ValueCount ( #_liste ) - 1 ) ; #_prefix; #_suffix ) ) )
                                                                                                                                                          AddPrefixSuffixToList2#_liste;#_prefix;#_suffix;#_zählerAll accounts// Description: // AddPrefixSuffixToList ( theList ; prefix ; suffix ) // A recursive function that takes a list of values and adds a prefix and suffix // Written by Andy Knasinski // www.nrgsoft.com // sample // AddPrefixSuffixToList ( "value1¶value2" ; "<value>" ; "</value>" ) // would return an XML string for all values in a field If ( IsEmpty ( #_liste ); #_liste ; Let ([ $$zähler = #_zähler ; #_zähler = 1 & ").Value = " ; $zähler2 = $zähler + 1 & ").Value = " ; aValue = GetValue ( #_liste ; 1 ) ]; #_prefix & aValue & #_suffix & If ( ValueCount ( #_liste ) > 1 ; "¶" ; "" ) & AddPrefixSuffixToList2 ( RightValues ( #_liste ; ValueCount ( #_liste ) - 1 ) ; #_prefix & #_zähler ; #_suffix ; $$zähler + 1) ) )

                                                                                                                                                            Custom Menu Sets

                                                                                                                                                            Menu SetsMenusIn ScriptsIn LayoutsComments
                                                                                                                                                            [Standard FileMaker Menus]
                                                                                                                                                            • All Standard Menus
                                                                                                                                                            Custom Menu Set 1

                                                                                                                                                            Download example: Email Client IMAP

                                                                                                                                                            Used functions:




                                                                                                                                                            Links
                                                                                                                                                            MBS Xojo tutorial videos