How to use the command line (Aid4Mail 5 Enterprise License)

The command-line switches in Aid4Mail 5 are completely different from version 4. Now, the names reflect exactly those in the Session INI file using a very simple rule. Values specified through the command line will always override matching values in the INI file.

You can find an example Session INI file attached to this article at the bottom. Here's the contents of the INI file:

[App]
AbortOnBadError=No
BatesCounter=1
CreateBackupOnFailure=Yes
EmailHashValue=MessageId
SessionUID=dbd8faaf

[Source]
Format=EML
RootLocation=D:\Email\Source\Test\EML\

[Filter]
Duplicates=FlagAll
IncludeEmptyFolders=No
IncrementalProcessing=No
ItemSearch=ItemScript
MapiProcessOnlyEmails=No
MaxSearchSize=32M
MinImageSize=32K
SaveIncrementalData=Yes
SearchAttachments=Yes
SearchFileMetadata=No
SearchInContainers=Yes
SmartCaseDetection=No
ItemScript=
ItemSearchCriteria=
Script=Test
FolderSearch=ProcessAll

[Modify]
AddMetadataToHeader=Yes
TargetFolderPathFormat=MirrorSource
Script=Test

[Target]
AppendMail=No
Format=MapiPst
RootLocation=
LimitPstFileSize=No Limit
MapiPst=D:\Email\Target\Test.pst

You can override any of the settings by specifying the section name (eg. Source), followed by a dot and then the key name (eg. RootLocation). Then you add a colon followed by the new value. Each command line switch is preceded by a hyphen.

Here is an example:

-Source.RootLocation:"D:\Email\Source\MSG\"

*We suggest that you first use the Aid4Mail GUI version to create a session with the appropriate settings you need for the Source and Target formats. After creating the session, you can find the Session INI file in the Project folder. You can then use this INI file in your command-line.

The Project folder is found here by default: C:\Users\USERNAME\Documents\Aid4Mail\Projects\Project-PROJECTNAME).

Here's a complete command line that overrides the source location and target PST file name:

a4m-32.exe -ini:"C:\Users\User\Projects\Demo\Test.settings.ini" -Source.RootLocation:"D:\Email\Source\MSG\" -Target.MapiPst:"D:\Email\Target\Outlook.pst"

If you experience any issues, please don't hesitate to contact us.

If you would like to buy an Aid4Mail license, please visit the Aid4Mail website.

Did you find it helpful? Yes No
Aid4Mail is a trademark licensed to Fookes Software Ltd. Fookes is a registered trademark of Fookes Holding Ltd. All other trademarks and service marks, both marked and not marked, are the property of their respective owners.