在自动化中配置获取多个节点操作,以从 XML 文件中提取多个节点值并将其保存到表变量中。
开始之前
- 一个名为 xml_sample.xml 的 XML 文件,包含以下示例:
<?xml version="1.0" encoding="UTF-8"?> <Customer> <Cust_Details> <custid city="Leon">A001</custid> <custname>XYZ Corp</custname> <custzipcode>15639</custzipcode> <country>Mexico</country> <Locale lang="es">Spanish</Locale> </Cust_Details> <Cust_Details> <custid city="Berlin">A002</custid> <custname>ABC GmbH</custname> <custzipcode>10115</custzipcode> <country>Germany</country> <Locale lang="de">German</Locale> </Cust_Details> <Cust_Details> <custid city="Tokyo">A003</custid> <custname>Tanaka Ltd</custname> <custzipcode>100-0001</custzipcode> <country>Japan</country> <Locale lang="ja">Japanese</Locale> </Cust_Details> </Customer> - 名为 TableXMLNodes 的表变量
过程
结果
A001
A002
A003