[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'Graphics' (#lcl)

# TPicture.LoadFromFile

LoadFromFile - Reads a picture from disk.

## Declaration

Source position: graphics.pp line 917

`public procedure TPicture.LoadFromFile(`
`const Filename: string`
`);`

## Arguments

`Filename` |  | The name of the file containing the picture, stored as a string.

## Description

LoadFromFile - Reads a picture from disk. The TGraphic class created is determined by the file extension of the file.

## Errors

If the file extension is not recognized, an exception is raised.