LMOutlookAddInConfig Usage Guide

Modified on Tue, 2 Apr at 1:27 AM

This usage guide provides the information necessary to understand and use the LMOutlookAddInConfig utility. This utility should be used to be able to support centralised management of the options available in the LawMaster Outlook Addin. 


This document contains the following sections: 

  • Utility Description: this section provides general details on the utility, where it can be obtained from and introduces the utilities capabilities. 
  • Command Line Arguments: this section describes the different arguments of the utility and the options that can be used with the utility. 
  • Configure Subject Rules: this section provides more detail on the command line argument that is used to define the rules that can be applied to the subject of an email. 
  • Exit Codes: the codes that will be returned when running the utility.


Utility Description


Outlook Add-In options for LawMaster are stored in a per-user and per-machine file "user.config". The location of this configuration file differs depending on the Add-In name and Outlook version.

 

A command-line configuration utility called LMOutlookAddinConfig.exe is available To enable centralised management of the options available in the LawMaster OutLook addin. This utility should be run as part of user login scripts, and will locate any relevant "user.config" files on the system and apply the settings specified using this utility. 


The program can be downloaded from: http://www.lawmaster.com.au/members/downloads/LMOutlookAddInConfig.exe


The characteristics of this utility are: 

  • It is a command-line utility. 
  • It must be run on the PC that is running Outlook, and will update settings only for the user executing the utility. 
  • The utility will only work if the Outlook Add-In has already been run once to create the configuration file. 


Running the utility with no arguments will present usage documentation, including all input arguments, and some examples. This utility provides access to the Outlook Add-In configuration that is also accessible through the "LAWMASTER" ribbon in Outlook. It is a utility that is intended to manage deployment of changes to those settings. 


The "Subject Rules" in particular, are more easily configured or "developed" using the Outlook Addin user interface, given the ability to "test" rules on sample input. 


So a settings development scenario might work as follows: 

  1. Use the "Configure Subject Rules" button in the LawMaster Outlook Add-In to create and test one or more email subject rules. 
  2. Run "LMOutlookAddInConfig.exe -outputfilepaths" to find the location of the Outlook Add-In config file. If Outlook has been updated, there will be more than one folder containing a config file, the folder for the highest version number will be the one in use. 
  3. Open the user.config file identified at step #2 and examine the settings, particularly those in the "MailSubjectReaderRules" setting, the "value" in this case, is one that can be passed directly to LMOutlookAddInConfig.exe using the -outboundsubjectrules argument. 


Command-Line Arguments 


This section describes all of the command-line arguments that can be used with the utility. The table names the argument and then provides a description of how this argument can be used. The arguments are presented in alphabetical order for ease of reference.


ArgumentDescription
-COMPENSATEONLI NEMODE {true|false} Set the flag for "Compensate for online / non-cached mode".
-DEFAULTSERVER "{server_name}"Set the "Default Server" value that specifies the LawMaster server to use to "server_name".
-OUTBOUNDCHECKS UBJECT {true|false}Set the save outbound email to folio "Check Subject" flag.
-OUTBOUNDSHOWS AVE {true|false}Set the save outbound email to folio "Show Save Dialog" flag.
-OUTBOUNDSUBJEC TRULES {json_serialised_settin gs}Set the rules for "Configure Subject Rules". See the following section in this guide, "Configure Subject Rules", for more information on using this argument.
-OUTPUTFILEPATHSOutputs a list of configuration files found on the system. If more than one version of the Outlook Addin has been installed previously on this computer then there will be more than one path. The path with the latest version number will be the version used by the Outlook Addin in setting its options.


For example, the command:

"LMOutlookAddInConfig.exe -DEFAULTSERVER "PracticeManagement Production" -OUTBOUNDSHOWSAVE false -COMPENSATEONLINEMODE false" 


Sets the following options for the current user on the current computer: 

  • The default server becomes PracticeManagement Production 
  • The user will not be shown the dialogue to save the email when an email is sent 
  • The Outlook client has been configured to operate in cached mode, LawMaster’s recommended option, so there is no need to compensate for the potentially slower response from the mail data store that may be experienced in direct mode.


These options will be shown in the LawMaster ribbon in Outlook as follows: 



Any property not specified as part of running the utility will remain configured with its existing value. Any change to the settings in the LawMaster ribbon from within Outlook will be saved in the user.config file. 


If no argument is provided to the utility a basic usage guide will be output summarising the information in this document. 


Another Example with Subject Rules:

C:\>LMOutlookAddInConfig.exe -OUTBOUNDSUBJECTRULES [{'FileType':'Matter','RuleType':'Regex','Rule':'matter.{0,3}[0-9]+'}] 


Configure Subject Rules 


The option to specify outbound subject rules is provided using the "-OUTBOUNDSUBJECTRULES" argument. Content for this input is a JSON serialised array of settings objects as shown in the following table.


JSON Field NameDescription
FileTypeMust be "Matter" or "Request" (internal use only for LawMaster)
RuleType"Contains" or "Regex".
RuleA string representing the rule, either the word/phrase to be searched for by a "Contains" rule, or a regular expression for "Regex" rule type.


"Contains" Rule

  • Ignores the punctuation characters , : ; - 
  • Is not case sensitive. 
  • The next whole number representation *after* the keyword in the subject determines file number. 
  • Regular expression. 
  • Case-sensitive. 
  • *All* numeric digits included in the regex result are converted to file number. e.g. if a regex matches "matter 12 44", the file number will be 1244.


"Regex" Rule


Any regular expression that .NET is capable of processing is valid. Microsoft’s documentation is at https://msdn.microsoft.com/en-us/library/hs600312 (v=vs.110).aspx


Example Imput


        { 

            'FileType':'Matter', 

            'RuleType':'Regex', 

            'Rule':'matter.{0,3}[0-9]+' 

        }, 

        { 

            'FileType':'Request', 

            'RuleType':'Contains', 

            'Rule':'request' 

        } 

]


Exit Codes

 

This section briefly describes the codes that may be returned from executing this utility in the %errorlevel% variable. The codes are shown in the following table. 


Return Code Value
Description
0Utility has executed correctly
1The configuration files has been updated
2An entry has been added to the configuration file
10An unrecognised error has occurred
11The configuration file was not found so could not be changed
12The utility was unable to read the configuration file
13The utility was unable to write to the configuration file
14No arguments were added to the command. Help text about the command will be output.


Appendix: Sample Outlook Addin Configuration File Layout 


This appendix contains a typical configuration XML file that will be located in a directory within a user’s local windows AppData directory. The name of the directory is generated by the LawMaster Outlook Addin can be identified by using the following command: 


LMOutlookAddInConfig –OUTPUTFILEPATHS 


If more than one version of the Outlook Addin has been used there will be more than one file path returned. The directory showing the latest version number will be the version of the file currently in use in configuring the Addin. 


A typical user.config file in this directory will look similar to the following:



Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article