Microsoft Dynamics 365 Blog

When you go to “CRM | Periodic | Import | Leads” you receive the following message in the InfoLog:

“An administrator must first configure or define a format for the Lead import”

This is because the CRM Import in Dynamics AX 2009 is based on XML files and AIF Classes. Before CRM Leads can be imported from an XML file, the AxBC classes to be used during the import have to be set up and an XSLT file (transform) to do the conversion has to be specified.

You need the following files to be able to do this:

  • SysImport.Leads.xsl
  • SysImport.Leads.xsd
  • Leads.xml

(the files are attached to this entry)

  1. Start Dynamics AX 2009 Client
  2. Go to Basic | Setup | Import | Documents
  3. Enter the following values in the Documents form:
    Name: CRMLead
  4. Description: CRM Lead Document Class
  5. Document Class: AxdSysImportLeads
  6. Click at the “Validate” button
  7. Verify an InfoLog shows up with the following message:
    “Information: Validation passed”
  8. Close the InfoLog
  9. Close the Documents form
  1. Go to Basic | Setup | Import |Transformations
  2. Enter the following values in the Transformations form:
    Name: XmlToLead
  3. Description: Converts generic Xml to Lead
  4. Document Class: CRMLead
  5. Click at the “Load” button
  6. Select the file “SysImport.Leads.xsl”
  7. Click at the “Validate” button
  8. Verify an InfoLog shows up with the following message:
    “Information: Validation passed”
  9. Go to the tab “General”
  10. Verify that “Type of transformation is” the value “XSLT”
  11. Verify the for the group “XSLT” the field “Content” is filled with the content of the xsl file
  12. Close the Transformations form
  1. Go to Basic | Setup | Import | Formats
  2. Enter the following values in the Formats form:
    Name: XmlFormat
  3. Description: Processes Xml Files
  4. Extenstions: *.xml
  5. Document Class: CRMLead
  6. Active: <Checked>
  7. Save the record ([CTRL]+[S])
  8. Click at the “Transformations” button
  9. Enter the following Values on the Format transformations form:
    Transformation: XmlToLead
  10. Close the Format transformations form
  11. Click on button “Validate” on the Formats form
  12. Verify that the Import form shows up
  13. Select the file “Leads.xml”
  14. Click on OK
  15. Verify an InfoLog shows up and contains the following message:
    “Validation passed”
  16. Close the Formats form

The CRM Leads import was now completely set up and you can start the import by going to:
CRM | Periodic | Import | Leads.

Please note:
If you received an error message on step 9 during validation “Field ‘Lead ID’ must be filled in.” make sure you have selected an automatic counting Number sequence for “Lead ID”.

–author: Alexander Lachner
–editor: Alexander Lachner
–date: 23/04/2009

We're always looking for feedback and would like to hear from you. Please head to the Dynamics 365 Community to start a discussion, ask questions, and tell us what you think!