Installation
Aspose.OCR for .NET is distributed as a NuGet package or as a downloadable file.
NuGet package
Aspose offers two options for Aspose.OCR for .NET NuGet package:
- Aspose.OCR - CPU-based OCR;
- Aspose.OCR-GPU - GPU-accelerated OCR (requires a CUDA capable GPU and NVIDIA CUDA Toolkit).
There is no need to download and install any software - the package can be added to your project directly from Microsoft Visual Studio. Both packages are installed and updated in the same way, so they will later be referred as “Aspose.OCR for .NET”.
Using NuGet Package Manager UI
NuGet Package Manager UI is the easiest way to install and update Aspose.OCR for .NET in your project.
Installing
- Open your solution or a project in Microsoft Visual Studio.
- Click Project menu and select Manage NuGet Packages.
Alternatively, you can right-click the project in Solution Explorer and select Manage NuGet Packages from the context menu. - Switch to Browse tab.
- Type “Aspose.OCR” (without quotes) in the search box.
- Select Aspose.OCR or Aspose.OCR-GPU package from the list (you only need to install one package).
- Click Install button.
You can select a specific version to be installed. However, it is recommended to always use the latest version for new projects. - If prompted, confirm changes to the solution.
- If prompted, accept the license terms for installed packages.
Updating
- Open your solution or a project in Microsoft Visual Studio.
- Click Project menu and click Manage NuGet Packages.
Alternatively, you can right-click the project in Solution Explorer and select Manage NuGet Packages from the context menu. - Select Aspose.OCR or Aspose.OCR-GPU package (depending on your installation option) from the list.
- Select the update version and click Update button.
- If prompted, confirm changes to the solution.
- If prompted, accept the license terms for update packages.
Using NuGet Package Manager Console
NuGet Package Manager Console lets you install and update Aspose.OCR for .NET in your project using PowerShell commands.
Installing
-
Open your solution or a project in Microsoft Visual Studio.
-
Click Tools menu, select NuGet Package Manager and click Package Manager Console.
-
Execute the command:
Install-Package Aspose.OCR
to install the latest version of Aspose.OCR NuGet package.Install-Package Aspose.OCR-GPU
to install the latest version of GPU-accelerated Aspose.OCR NuGet package.
Updating
-
Open your solution or a project in Microsoft Visual Studio.
-
Click Tools menu, select NuGet Package Manager and click Package Manager Console.
-
Checks if there are newer versions available for any installed packages by executing a command
Get-Package -updates
. If an update is available, you will see something like this:Id Versions Description ProjectName -- -------- ----------- ----------- Aspose.OCR {22.3.0} Aspose.OCR for .NET is a standalone OCR API... ConsoleApp1
-
Update Aspose.OCR for .NET to the latest version by executing a command
Update-Package Aspose.OCR
(if you are using Aspose.OCR NuGet package) orUpdate-Package Aspose.OCR-GPU
(if you are using GPU-accelerated Aspose.OCR NuGet package).To update to a specific version, provide its name in the
-Version
parameter . For example:Update-Package Aspose.OCR -Version 22.5.0
.
Downloadable
To use a downloaded Aspose.OCR component in your application:
- Open your solution or a project in Microsoft Visual Studio.
- Expand the project tree in Solution Explorer.
- Right-click References and select Add COM Reference (for .NET Core project) or Add Reference (for .NET Framework project) from the context menu.
- Click Browse… button and locate Aspose.OCR.dll file.
- Install the required dependencies from NuGet.
- Click OK button.
Aspose.OCR will appear under the project’s References folder.