SpreadsheetGear 2023
SpreadsheetGear Explorer for .NET Sample Solution
SpreadsheetGear 2023 > Getting Started > Using the Samples > SpreadsheetGear Explorer for .NET Sample Solution

SpreadsheetGear 2023 for .NET Framework comes with the SpreadsheetGear Explorer sample solutions which are helpful Windows Forms applications for Visual Studio 2013.  Visual Studio 2015, Visual Studio 2017, Visual Studio 2019 and Visual Studio 2022 will offer to convert these solutions to Visual Studio 2013 / 2015 / 2017 / 2019 / 2022 solutions the first time they are opened.

The SpreadsheetGear Explorers are available with C# and Visual Basic source code and are composed of a set of user controls, each of which demonstrates commonly used SpreadsheetGear 2023 functionality and API's. Source code can be viewed and copied directly from the source viewer below each sample. Follow the steps below to open and run the SpreadsheetGear Explorer solutions from Windows (requires a version of Visual Studio which supports Windows Forms solutions and either C# or Visual Basic).

Please see Troubleshooting SpreadsheetGear Explorer below if you are having problems running the samples. 

Running the SpreadsheetGear Explorer Sample Solutions

  1. Install SpreadsheetGear 2023 for .NET Framework.
  2. In Windows 10 or Windows 11 open the Windows Start menu, click on SpreadsheetGear 2023 and click on SpreadsheetGear Explorer C# Sample or SpreadsheetGear Explorer VB Sample.
  3. In Windows 8.1 navigate to the Windows Start Screen, start typing "SpreadsheetGear Explorer", and click on SpreadsheetGear Explorer C# Sample or SpreadsheetGear Explorer VB Sample.
  4. In earlier versions of Windows open the Windows Start menu, click on All Programs, click on SpreadsheetGear 2023, click on SpreadsheetGear 2023 for .NET, click on SpreadsheetGear Explorer C# Sample or SpreadsheetGear Explorer VB Sample.
  5. If you are opening the solution in Visual Studio 2013, Visual Studio 2015, Visual Studio 2017, Visual Studio 2019 or Visual Studio 2022 for the first time, follow the steps in the Visual Studio Conversion Wizard to convert the solution to Visual Studio 2013 / 2015 / 2017 / 2019 / 2022.
  6. For the best performance, make sure that the current configuration is set to Release rather than Debug.
  7. Open the Build menu and choose Rebuild Solution.
  8. Open the Debug menu and choose Start Without Debugging to run SpreadsheetGear Explorer.
  9. In SpreadsheetGear Explorer, choose among the various samples on the left. Note that many of the samples require user input, such as clicking on a Run Sample button or entering the specified text or number into a cell.
  10. Source code can be viewed and copied directly at runtime from the source viewer below each sample.
  11. It is important to note that the SpreadsheetGear Explorer samples demonstrate the usage of GetLock and ReleaseLock which are required when using the WorkbookView control with background calculation enabled. ASP.NET developers will almost never use GetLock and ReleaseLock, and at the time of this writing none of the ASP.NET samples provided by SpreadsheetGear LLC use GetLock and ReleaseLock.

Troubleshooting SpreadsheetGear Explorer

You may run into problems with the SpreadsheetGear Explorer samples. Common problems fall into one of two categories:

To avoid these problems, manually run Visual Studio as an Administrator and open the SpreadsheetGear Explorer Sample solution from 'INSTALLDIR\SpreadsheetGear\SpreadsheetGear 2023 for .NET\DotNet35\Samples\' where INSTALLDIR is typically 'C:\Program Files\' on Windows x86 or 'C:\Program Files (x86)\' on Windows x64.

As an alternative, you may prefer to copy the samples to a directory in which you have the appropriate permissions and then open them in Visual Studio.