# Read Line from File

Reads the contents of a file sequentially, line by line, and outputs a string for each of the lines.

Connect the last block from the sequence connected to this connector to the input of the block to close the loop.

<table data-header-hidden><thead><tr><th width="235" valign="top"></th><th width="335" valign="top"></th></tr></thead><tbody><tr><td valign="top">File Name</td><td valign="top">[Text] The name of the text file whose contents need to be read. You can enter the full file name including the path.</td></tr><tr><td valign="top">Encoding</td><td valign="top">The encoding of the file.</td></tr><tr><td valign="top">Skip Empty Lines</td><td valign="top">If selected, empty lines will be skipped.</td></tr><tr><td valign="top">Line</td><td valign="top">[Text] The line read from the file.</td></tr><tr><td valign="top">Line Index</td><td valign="top">[Number] The ordinal number of the read line. Numbering starts from zero.</td></tr><tr><td valign="top">Error Handling Level</td><td valign="top"><p>Select the error handling level. Possible values:</p><ul><li>"Default" - default;</li><li>"Ignore" - errors are ignored;</li><li>"Handle" - errors are handled.</li></ul><p>If "Default" is selected, the value of the "Start" block of this diagram will be used.</p></td></tr><tr><td valign="top">Output Direction</td><td valign="top"><p>Select the output direction from the block in case of an error. Possible values:</p><ul><li>"Default" - default;</li><li>"Right" - to the right;</li><li>"Bottom" - down.</li></ul><p>This property allows you to determine the output direction in case of errors for blocks that do not contain the "If Error" connector (for example, the "Condition" block).</p><p>If "Default" is selected, the value of the "Start" block of this diagram will be used.</p></td></tr><tr><td valign="top">Message Level</td><td valign="top"><p>Select the message level that the blocks will output during operation.</p><p>Possible values:</p><ul><li>"Default" - default;</li><li>"Release" - output is disabled;</li><li>"Debug" - main information output;</li><li>"Detailed" - detailed information output.</li></ul><p>If "Default" is selected, the value of the "Start" block of this diagram will be used.</p></td></tr><tr><td valign="top">Error Text</td><td valign="top">[Text] Returns detailed information about the error in case of incorrect execution of the block's work.</td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.sherparpa.ru/en/sherpa-rpa/sherpa-designer/spravochnik-blokov/failovaya-sistema-file-system/schitat-stroku-iz-faila-filelineread.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
