Summary
Description
Certain data from Sage 200 is surfaced immediately in Sales, Marketing and Service the moment the connection between the two programs has been established and records have been imported. It's possible to further extend this functionality to include additional information from Sage 200 and add them as new fields in the screens.
NOTE: This process differs from adding buttons to screens found in the Finance and Commercials tab of the Company record. For details of how to extend this functionality, please refer to Ask Sage article.
Resolution
The example below explains how to add the 'Analysis Code 1' field to the Company Summary Screen in Sales, Marketing and Service. The same methodology can be used to add alternative fields in the same manner but please ensure this is tested to ensure the desired outcome is achieved first.
NOTE: This article has been updated to reflect the release of version 4.1 of the CRM Connector. If you are using version 3.1, please refer to the documentation that accompanies this version as the steps required are different from those described below.
Finding the Analysis Code 1 field details
- Select Administration > Customisation.
- Using the Secondary Entities menu, select wsS200Customer.
- Select the Fields tab.
- In the Field Caption column, select Analysis Code1 and make a note of the following details:
- Entry Type
- Column Name
- Caption
- Max Length
Make the field available to the Company entity
A new field needs to be added to the Company entity which can be linked to the Analysis Code 1 field of the relevant Sage 200 Extra Sales Ledger record.
- Select Administration > Customisation > Company.
- Select the Fields tab.
- Select New and enter the following details:
- Entry Type: Text
- Column Name: Comp_analysiscode1
- Caption: Sales Rep
- Max length: 60
- Select Save.
Add the field to the Company Grid list
The new field must now be added to the Company list.
- Select Administration > Customisation > Company.
- Select the Lists tab.
- Select Company Grid.
- From the 'Field:' drop down list, select Company: Analysis Code 1 (comp_analysiscode1).
- Select Add.
TIP: You can alter the column position by moving the field up and down the list using the green arrows. By default, it will be added as the last column in the list.
- Select Save.
To check the new fields appears as a column on the results grid correctly, use Find > Company.
NOTE: At this stage, the contents of the column will be blank.
Add the field to the Company Search screen
The new field can now be added to the Company Search screen.
- Select Administration > Customisation > Company.
- Select the Screens tab.
- Select Company Search screen.
- From the 'Field:' drop down list, select Company: Analysis Code 1 (comp_analysiscode1).
- Select Add.
TIP: You can alter the screen position of the field by moving it up and down the list using the green arrows. By default, it will be added as the last field on the screen.
- Select Save.
To check the new fields appears as a field on the Company Search screen correctly, use Find > Company.
NOTE: At this stage, there will be no results returned if searching on this field.
Add the field to the Company Entry screen
The new field can now be added to the Company Entry screen.
- Select Administration > Customisation > Company.
- Select the Screens tab.
- Select Company Entry screen.
- From the 'Field:' drop down list, select Company: Analysis Code 1 (comp_analysiscode1).
- Select Add.
TIP: You can alter the screen position of the field by moving it up and down the list using the green arrows. By default, it will be added as the last field on the screen.
- Select Save.
To check the new fields appears as a field on the Company Search screen correctly, use New > Company.
Map the Analysis Code 1 field to the Sage 200 Extra field.
To map the new field in Sage CRM to the field that exists in Sage 200 Extra, the FieldMappings.inc file needs to be edited to include details of the new relationship.
- Open Windows Explorer and browse to the CRM installation folder. The default folder is C:\Program Files (x86)\Sage\CRM\CRM.
- From the installation folder, open the folder WWWRoot > CustomPages > Enbu > Framework > S200 > Custom.
- Open FieldMappings.inc in Notepad.
- Under the section that begins function RunFieldMappings_Custom(, find the last line which starts: // Example: updateByMaster(compRecord,
- Add the following text to the next line before the closing } symbol...
updateByMaster(compRecord, "comp_analysiscode1", customerRec, "analysiscode1", ERPisMaster); // map comp_analysiscode1
- Save the file.
Populate the Analysis Code 1 field with existing data
Now that the field has been added to CRM and mapped to the field in Sage 200 Extra, the existing data for that field will need to be added to Sage CRM.
To populate newly created fields in CRM with data from Sage 200 Extra, it is necessary to change the migration mode within the Sage CRM Connector Configuration screen. This will force all data for fields listed in FieldMappings.inc to be brought through from Sage 200 Extra, populating any new fields with data as necessary.
To enable Migration mode
Migration mode can be enabled in the Migration.asp file. This forces Sage 200 Extra to become the master for all records and means a full sync is performed the next time the service is ran via the Windows Task Scheduler or the 'Import and Sync' button in CRM. To enable migration mode, follow the steps below.
- Administration > Sage CRM Connector Configuration.
- Select Change.
- Select the checkbox for Migrate Mode.
- Select Save.
- Administration > Sage CRM Connector > S200 Account Migration tab.
- Select Display ERP Accounts.
- Select Import & Sync.
- Once the progress bar reaches 100%, select Continue.
- Return to the Sage CRM Connector Configuration screen and de-select the Migrate Mode checkbox.
- Select Save.
You can then use the Find > Company screen to search for a company - the details should then be populated for the new custom field.