> ## Documentation Index
> Fetch the complete documentation index at: https://rpa.bazhuayu.com/helpcenter/llms.txt
> Use this file to discover all available pages before exploring further.

# 读取Excel内容

## 指令说明

**描述：** 读取 Excel 工作表中的单元格、行、列或指定区域内容，并保存为流程变量。

## 参数说明

<Tabs>
  <Tab title="常规">
    <img src="https://mintcdn.com/bazhuayu-rpa-docs/XU4apql8B34CRdwD/helpcenter/commands/excel/images/readexcelcommand-10.png?fit=max&auto=format&n=XU4apql8B34CRdwD&q=85&s=42ad3fef8cd20d7e206bd942de95ad32" alt="读取Excel内容指令参数面板" width="642" height="570" data-path="helpcenter/commands/excel/images/readexcelcommand-10.png" />

    | 参数           | 说明                                                         |
    | ------------ | ---------------------------------------------------------- |
    | **Excel对象**  | 请选择 Excel 对象（可通过【启动Excel】或【获取当前激活的Excel对象】创建），用于确定待操作的工作簿。 |
    | **Sheet页名称** | 操作目标工作表的名称，支持选填，默认为当前 Excel 激活的 Sheet 页。                   |
    | **读取方式**     | 选择需要读取的内容类型：单元格、行、列或区域。                                    |
    | **其他参数**     | 根据读取方式填写对应的行号、列号或区域范围。                                     |
  </Tab>

  <Tab title="高级">
    <img src="https://mintcdn.com/bazhuayu-rpa-docs/XU4apql8B34CRdwD/helpcenter/commands/excel/images/readexcelcommand-11.png?fit=max&auto=format&n=XU4apql8B34CRdwD&q=85&s=f84ff571751e3bc689629dbe1b59500e" alt="读取Excel内容高级参数面板" width="639" height="250" data-path="helpcenter/commands/excel/images/readexcelcommand-11.png" />

    | 参数             | 说明                                         |
    | -------------- | ------------------------------------------ |
    | **读取单元格显示的内容** | 勾选后返回与 Excel 显示一致的文本内容；未勾选时，结果会根据数据类型进行转换。 |
  </Tab>
</Tabs>

## 使用示例

<img src="https://mintcdn.com/bazhuayu-rpa-docs/XU4apql8B34CRdwD/helpcenter/commands/excel/images/readexcelcommand-12.png?fit=max&auto=format&n=XU4apql8B34CRdwD&q=85&s=fff7f10f90cc06b7477c85ab747238b2" alt="读取Excel内容使用示例 - 流程搭建" width="687" height="151" data-path="helpcenter/commands/excel/images/readexcelcommand-12.png" />

**该流程执行逻辑：**

1. 使用【启动Excel】打开目标工作簿并生成 Excel 对象。
2. 执行【读取Excel内容】，选择默认 Sheet，按行读取第 1 行数据。
3. 将读取到的单元格内容保存到结果变量，供后续数据处理或写入操作使用，最后按需要关闭 Excel。

### 效果展示

<img src="https://mintcdn.com/bazhuayu-rpa-docs/XU4apql8B34CRdwD/helpcenter/commands/excel/images/readexcelcommand-13.png?fit=max&auto=format&n=XU4apql8B34CRdwD&q=85&s=5623034c83521afefe9b4620ba4ce5b6" alt="读取Excel内容效果展示 - Excel源数据" width="1605" height="254" data-path="helpcenter/commands/excel/images/readexcelcommand-13.png" />

<img src="https://mintcdn.com/bazhuayu-rpa-docs/XU4apql8B34CRdwD/helpcenter/commands/excel/images/readexcelcommand-14.png?fit=max&auto=format&n=XU4apql8B34CRdwD&q=85&s=89597144b196010152dcda420ce06a96" alt="读取Excel内容效果展示 - 运行日志" width="1301" height="210" data-path="helpcenter/commands/excel/images/readexcelcommand-14.png" />

<img src="https://mintcdn.com/bazhuayu-rpa-docs/XU4apql8B34CRdwD/helpcenter/commands/excel/images/readexcelcommand-15.png?fit=max&auto=format&n=XU4apql8B34CRdwD&q=85&s=d52e7552883a174768b12e0dfe94727e" alt="读取Excel内容效果展示 - 读取结果" width="1169" height="233" data-path="helpcenter/commands/excel/images/readexcelcommand-15.png" />

<Info>
  使用指令过程中遇到问题？前往 [八爪鱼RPA 开发者社区问答板块](https://rpa.bazhuayu.com/community/questions) 提问，获取官方与社区帮助。
</Info>
