This article applies to:
This item was introduced in E-Prime 184.108.40.206.
E-Prime allows List objects to be populated at runtime from an Excel XML file (Earlier versions of E-Prime were restricted to text files). The List is populated from the first worksheet of the spreadsheet; any additional worksheets are ignored. To set the contents of the List from an XML file, set the Load Method property of the List to "File" and the Filename property to the name of the XML file. As with other experiment resource files, we recommend placing the XML file in the same folder as the experiment specification file (i.e., .es3, .es2). By doing so, no path information needs to be included in the Filename property.
To create an XML file in Excel, configure the first spreadsheet in the workbook as follows:
- Enter the required Attribute names Weight, Nested, and Procedure on the first row (row 1). (Unlike when populating the List from a text file, these attribute names do not have to be listed in order or as the first three column headings.)
- Add additional column headings for the experiment-specific attributes.
- Enter rows of attribute values as needed beneath the Attribute names. For any blank values (for example if not using Nested lists), leave the cell empty.
- Save the file in Excel by choosing "Save As" and then selecting "XML Spreadsheet" from the "Save As Type" dropdown.
To reference the XML file on the List object*:
- Select the List Object in the Structure.
- If not already completed, configure the List to reflect the procedure to be run and the Attributes that are defined in the text file. The List should contain a single row and the Procedure should be set to the name of the Procedure Object to be run (and should match the value defined in the text file). Specifying the Procedure enables the Structure view to show the sequence of objects that will be presented when the experiment runs. Specifying the Attribute names allows the AttribSense feature to reference the Attributes on Text and Slide sub-objects.
- While not required, we recommend setting the Weight for the single row on the List to 0.
- Open the Properties Window.
- Set the LoadMethod to "File".
- Set the Filename to the name of the XML file that will populate the LIst when the experiment runs.
NOTE: The List object is not updated to show the contents of the file; instead, the contents of the List are not populated until the experiment runs. When the List object is edited in E-Studio to set the LoadMethod to "Filename" then the contents of the Weight, Nested, and Procedure columns are greyed out and are no longer editable to indicate that the List contents are assigned from an external file.
*This is the same process as used when populating the List from a text file.
To run the example experiment, download either the E-Prime 2.0 or E-Prime 3.0 zip file. Extract all files to the same location; the XML file must be in the same folder as the .es2 or .es3 file.
Legacy End User Comments
|Make sure to save as "XML Spreadsheet", *not* "XML Data".|
|By default, the Filename File Open dialog will not find .xml files. To select an .xml file using the File Open dialog, first change Files of Type from the default "Text Files (*.txt)" to "All Files (*.*)".|
|A future update of E-Prime will include search pattern in the dialog to choose .txt and .xml files.|