When a visitor submits a form which has the “Push Sitecore Analytics” checkbox ticked in the S4S mapping, it will identify the current Sitecore visitor by calling the IdentifyAs() method and then create/edit the Salesforce object and push Sitecore analytics to Salesforce. The IdentifyAs() method requires two parameters called “source” and “identifier”. The Value for the “source” is configured in the S4S.Analytics.IdentifierSource setting in the /App_Config/Include/S4SAnalytics.config file.

<!-- The source to use for identifiers -->
<setting name="S4S.Analytics.IdentifierSource" value="S4S" />

The value for the "identifier" is retrieved from the form field configured in the S4S.Analytics.Identifier setting in the /App_Config/Include/S4SAnalytics.config file.

<!-- The name of the field containing the identifier-->
<setting name="S4S.Analytics.Identifier" value="Email" />

The form field used to identify a Sitecore Contact is set to a default of Email. You can change the above entry so that it specifies another form field that is to be used for identifying a Contact. Once the field has been configured, the Save Action will look in the form for the field and use its value as the identifier for the Contact.

IMPORTANT: By default, the Sitecore identifier is case sensitive. From S4S version 2.931.20224.1 and above, there is a new config setting called “S4S.Analytics.ConvertIdentifierValueToLowerCase” in the /App_Config/Modules/S4S/S4SAnalytics.config file to make Identifier property case insensitive when using S4S.


 

IMPORTANT: When submitting Lead or Contact Analytics data with S4S Sitecore Experience Forms, you may see Sitecore Error Log entries like the following:

42444 11:26:31 ERROR Error: FuseIT.Sitecore.SalesforceConnector.Services.SalesforceServiceFoundation - Errors in upsert results. Failed Records Count =3

This is due to S4S saving analytics data using the S4S DisparateSalesforceService to conserve API calls. If records already exist Sitecore Visits, Goals or Profiles from a previous form submission or from the Bulk Update Analytics job, the those inserts will fail. While it is logged as an error in Sitecore, there will be no error in the data that is recorded against the Lead or Contact.

Please see the following link if you are experiencing errors in the Mapping Wizard user interface:

S4S Form Mapping Wizard Error

Next Step

Custom Submit Action

Steps