Create a template for value accessors

Abstract

How to specify which array values to read by creating a value accessor template in Sitecore Data Exchange Framework.

In this walkthrough, each row from the input text file is split into an array of values. The individual values in the array can be used in a data synchronization process. You need to configure a template that lets a user specify which value in the array to read.

Create a template

To create a template:

  1. In Sitecore Content Editor, navigate to Templates.

  2. In the menu ribbon, on the Home tab, click New Template to add a new template.

    New template option in menu ribbon
  3. Enter the following values:

    Field

    Value

    Name

    Array Value Accessor

    Base template

    Templates/Data Exchange/Framework/Data Access/Value Accessors/Value Accessor

  4. Click Next.

  5. In the Location dialog, select Templates/Data Exchange/Providers/File System/Data Access/Value Accessors. Click Next.

  6. On the confirmation dialog, click Close.

Set an icon

To set an icon:

  1. In the Content Editor, in the content tree, select the new template.

    new-template-selected.png
  2. Click the Content tab.

  3. Click the icon next to the title.

    icon.png
  4. In the Change Icon window, in the Icon field, enter Office/32x32/radio_button_selected.png

  5. Click OK.

Add a field

To add a field:

  1. Add a template section and name it Settings.

  2. Add the following fields:

    Field

    Value

    Name

    Position

    Type

    Integer

    Shared

    selected

  3. Save the item.