---
title: "Load images from local storage in C# | Nutrient .NET SDK"
canonical_url: "https://www.nutrient.io/guides/dotnet/load-a-file/imaging/from-local-storage-image/"
md_url: "https://www.nutrient.io/guides/dotnet/load-a-file/imaging/from-local-storage-image.md"
last_updated: "2026-05-21T17:12:02.207Z"
description: "Learn how to efficiently load images from local storage in C# using GdPictureImaging methods with clear examples."
---

# Load images from local storage in C#

### Image

[Image](https://www.nutrient.io/guides/dotnet/load-a-file/imaging/from-local-storage-image.md)

### Bitmap

[Bitmap](https://www.nutrient.io/guides/dotnet/load-a-file/imaging/from-local-storage-bitmap.md)

### SVG

[SVG](https://www.nutrient.io/guides/dotnet/load-a-file/imaging/from-local-storage-svg.md)

### DICOM

[DICOM](https://www.nutrient.io/guides/dotnet/load-a-file/imaging/from-local-storage-dicom.md)

### TIFF

[TIFF](https://www.nutrient.io/guides/dotnet/load-a-file/imaging/from-local-storage-tiff.md)

### More...

[More...](https://www.nutrient.io/guides/dotnet/load-a-file/imaging/from-local-storage-more.md)

To load an image from local storage, use the [`CreateGdPictureImageFromFile` method](https://www.nutrient.io/api/gdpicture/GdPicture.NET.14~GdPicture14.GdPictureImaging~CreateGdPictureImageFromFile.html) of the [`GdPictureImaging` class](https://www.nutrient.io/api/gdpicture/GdPicture.NET.14~GdPicture14.GdPictureImaging.html).

This method returns a non-zero GdPicture image identifier (`imageID`) when successful. If it fails, it returns `0` — use `GetStat()` to get the failure reason.

`CreateGdPictureImageFromFile` has overloads that let you specify:

- `FilePath` — Path to the image file (or empty string to prompt file selection on Windows).

- `LoadInMemory` (optional, default `false`) — Loads file content into memory for better manipulation performance.

- `DirectAccess` (optional, default `false`) — Loads only properties/metadata/embedded thumbnail (no pixel decoding). Pixel-dependent operations will fail in this mode.

Use the [`GetLastPath` method](https://www.nutrient.io/api/gdpicture/GdPicture.NET.14~GdPicture14.GdPictureImaging~GetLastPath.html) to retrieve the last loaded/saved file path used by the `GdPictureImaging` instance.

When you no longer need an image resource, release it with the [`ReleaseGdPictureImage` method](https://www.nutrient.io/api/gdpicture/GdPicture.NET.14~GdPicture14.GdPictureImaging~ReleaseGdPictureImage.html).

To load an image from local storage, use the following code:

### C#

```csharp

using GdPicture14;

using GdPictureImaging gdpictureImaging = new GdPictureImaging();

int imageID = gdpictureImaging.CreateGdPictureImageFromFile(@"C:\temp\source.jpg", false);
if (imageID == 0)
{
    Console.WriteLine($"Load failed: {gdpictureImaging.GetStat()}");
    return;
}

GdPictureStatus status = gdpictureImaging.SaveAsPNG(imageID, @"C:\temp\output.png");
if (status!= GdPictureStatus.OK)
{
    Console.WriteLine($"Save failed: {status}");
}

gdpictureImaging.ReleaseGdPictureImage(imageID);

```

### VB.NET

```vb

Imports GdPicture14

Using gdpictureImaging As New GdPictureImaging()
    Dim imageID As Integer = gdpictureImaging.CreateGdPictureImageFromFile("C:\temp\source.jpg", False)
    If imageID = 0 Then
        Console.WriteLine($"Load failed: {gdpictureImaging.GetStat()}")
        Return
    End If

    Dim status As GdPictureStatus = gdpictureImaging.SaveAsPNG(imageID, "C:\temp\output.png")
    If status <> GdPictureStatus.OK Then
        Console.WriteLine($"Save failed: {status}")
    End If

    gdpictureImaging.ReleaseGdPictureImage(imageID)
End Using

```
---

## Related pages

- [Load a vector image (SVG) from a byte array in C#](/guides/dotnet/load-a-file/imaging/from-byte-array-svg.md)
- [Load a DICOM image from a byte array in C#](/guides/dotnet/load-a-file/imaging/from-byte-array-dicom.md)
- [Load a bitmap (BMP) from a byte array in C#](/guides/dotnet/load-a-file/imaging/from-byte-array-bitmap.md)
- [Load an image from a byte array in C#](/guides/dotnet/load-a-file/imaging/from-byte-array-image.md)
- [Load a TIFF from a byte array in C#](/guides/dotnet/load-a-file/imaging/from-byte-array-tiff.md)
- [Load a TIFF from local storage in C#](/guides/dotnet/load-a-file/imaging/from-local-storage-tiff.md)
- [Load a bitmap (BMP) from a remote URL in C#](/guides/dotnet/load-a-file/imaging/from-remote-url-bitmap.md)
- [Load a DICOM image from local storage in C#](/guides/dotnet/load-a-file/imaging/from-local-storage-dicom.md)
- [Load a vector image (SVG) from local storage in C#](/guides/dotnet/load-a-file/imaging/from-local-storage-svg.md)
- [Load images using the API in C#](/guides/dotnet/load-a-file/imaging/from-local-storage-more.md)
- [Load a DICOM image from a remote URL in C#](/guides/dotnet/load-a-file/imaging/from-remote-url-dicom.md)
- [Load an image from a remote URL in C#](/guides/dotnet/load-a-file/imaging/from-remote-url-image.md)
- [Load a TIFF from a stream in C#](/guides/dotnet/load-a-file/imaging/from-stream-tiff.md)
- [Load a bitmap (BMP) from local storage in C#](/guides/dotnet/load-a-file/imaging/from-local-storage-bitmap.md)
- [Load a vector image (SVG) from a remote URL in C#](/guides/dotnet/load-a-file/imaging/from-remote-url-svg.md)
- [Load a bitmap (BMP) from a stream in C#](/guides/dotnet/load-a-file/imaging/from-stream-bitmap.md)
- [Load a TIFF from a remote URL in C#](/guides/dotnet/load-a-file/imaging/from-remote-url-tiff.md)
- [Load an image from a stream in C#](/guides/dotnet/load-a-file/imaging/from-stream-image.md)
- [Load a DICOM image from a stream in C#](/guides/dotnet/load-a-file/imaging/from-stream-dicom.md)
- [Load a vector image (SVG) from a stream in C#](/guides/dotnet/load-a-file/imaging/from-stream-svg.md)

