Adding additional fields to the Company Summary screen in Sales, Marketing and Service

One of the benefits of using the Sales, Marketing and Service module of Sage 200 is the ability to customise various screens within the program.

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 34440.

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

  1. Select Administration > Customisation.
  2. Using the Secondary Entities menu, select wsS200Customer.
  3. Select the Fields tab.
  4. 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.

  1. Select Administration > Customisation > Company.
  2. Select the Fields tab.
  3. Select New and enter the following details:

    • Entry Type: Text
    • Column Name: Comp_analysiscode1
    • Caption: Sales Rep
    • Max length: 60
  4. Select Save.

Add the field to the Company Grid list

The new field must now be added to the Company list.

  1. Select Administration > Customisation > Company.
  2. Select the Lists tab.
  3. Select Company Grid.
  4. From the 'Field:' drop down list, select Company: Analysis Code 1 (comp_analysiscode1).
  5. 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.

  6. 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.

  1. Select Administration > Customisation > Company.
  2. Select the Screens tab.
  3. Select Company Search screen.
  4. From the 'Field:' drop down list, select Company: Analysis Code 1 (comp_analysiscode1).
  5. 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.

  6. 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.

  1. Select Administration > Customisation > Company.
  2. Select the Screens tab.
  3. Select Company Entry screen.
  4. From the 'Field:' drop down list, select Company: Analysis Code 1 (comp_analysiscode1).
  5. 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.

  6. 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.

  1. Open Windows Explorer and browse to the CRM installation folder. The default folder is C:\Program Files (x86)\Sage\CRM\CRM.
  2. From the installation folder, open the folder WWWRoot > CustomPages > Enbu > Framework > S200 > Custom.
  3. Open FieldMappings.inc in Notepad.
  4. Under the section that begins function RunFieldMappings_Custom(, find the last line which starts: // Example: updateByMaster(compRecord,
  5. Add the following text to the next line before the closing } symbol...

    updateByMaster(compRecord, "comp_analysiscode1", customerRec, "analysiscode1", ERPisMaster); // map comp_analysiscode1

  6. 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.

  1. Administration > Sage CRM Connector Configuration.
  2. Select Change.
  3. Select the checkbox for Migrate Mode.
  4. Select Save.
  5. Administration > Sage CRM Connector > S200 Account Migration tab.
  6. Select Display ERP Accounts.
  7. Select Import & Sync.

  8. Once the progress bar reaches 100%, select Continue.

  9. Return to the Sage CRM Connector Configuration screen and de-select the Migrate Mode checkbox.

  10. 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.