Questions tagged [gembox-spreadsheet]

GemBox.Spreadsheet is a .NET component that enables you to read, write, convert, and print spreadsheet files (XLSX, XLS, XLSB, CSV, HTML, and ODS) from .NET applications. With GemBox.Spreadsheet you get a fast and reliable component that’s easy to use and doesn't depend on Microsoft Excel. It requires only .NET and it’s much faster than Microsoft Office Automation!

GemBox.Spreadsheet () is a .NET component that enables developers to read, write, and convert spreadsheet files from their .NET applications.

GemBox.Spreadsheet Free is free of charge while GemBox.Spreadsheet Professional is a commercial version licensed per developer. Server deployment is royalty-free.


Support

Read Read & Write Write
XML XLS, XLT PDF, PDF/A
XLSX, XLTX, XLSM, XLSM XPS
XLSB PNG, JPG, GIF, BMP, TIFF
ODS
CSV, TSV
HTML, MHTML
PRN, TXT

Hello World

C#

// Create a new file.
ExcelFile workbook = new ExcelFile();

// Create a new sheet.
ExcelWorksheet worksheet = workbook.Worksheets.Add("Sheet 1");

// Get cell "A1".
ExcelCell cell = worksheet.Cells["A1"];

// Set cell value to "Hello World".
cell.Value = "Hello World";

// Save as XLSX file.
workbook.Save("Output.xlsx");

VB.NET

' Create a new file.
Dim workbook As New ExcelFile()

' Create a new sheet.
Dim worksheet As ExcelWorksheet = workbook.Worksheets.Add("Sheet 1")

' Get cell "A1".
Dim cell As ExcelCell = worksheet.Cells("A1")

' Set cell value to "Hello World".
cell.Value = "Hello World"

' Save as XLSX file.
workbook.Save("Output.xlsx")

Top Features


System Requirement

  • .NET Framework 3.5 - 4.8
  • .NET Core 3.1 (.NET 5 & 6 for Windows)
  • .NET Standard 2.0 (.NET 5 & 6 for Linux, macOS, Android, iOS, …)

Installation

You can download GemBox.Spreadsheet from NuGet

Or from BugFixes


Resources


Related Tags

115 questions
1
vote
1 answer

Gembox null value breaking formula

I am creating an Excel spread sheet using C# and Gembox. I get the data from SQLServer in a datatable and I have a situation where if a cell in the datatable is null, putting that into the excel object results in any formulas that rely on that Excel…
Percy
  • 2,855
  • 2
  • 33
  • 56
1
vote
3 answers

GemBox Spreadsheet

How can I retrieve data from a worksheet into a string variable? There seems to be no method for it. var workbook = ExcelFile.Load("Workbook.xls"); var worksheet = workbook.Worksheets[0]; How do I get the data in a worksheet into a string? Kindly…
1
vote
1 answer

Is there a way to import an image from excel to a PictureBox?

I am writing an application that works with Excel files. So far I have been using Gembox spreadsheet to work with excel files. However, I discovered using Gembox spreadsheet I can save pics to excel files, but not retrieve them. Anyone can recommend…
M. Levin
  • 163
  • 1
  • 11
1
vote
1 answer

Programatic truncation of large file names (zipped) for different Windows editions

So I'm bugfixing on a program that allows a user to create an Excel document, which it first zip compresses before serving to the customer. One of the client complaints is that, while the zip file can always be downloaded, sometimes the user must…
1
vote
1 answer

Gem Box Spreadsheet msi error

I have to do a Excel Manager with C# and i choose to use Gem Box Spreadsheet Free var ef = new ExcelFile(); ef = ExcelFile.Load(File_Lettura); ExcelWorksheet ws = ef.Worksheets.ActiveWorksheet; int riga = 13; …
stewgh
  • 11
  • 1
1
vote
1 answer

Excel file not loaded correctly

I am using Gembox-spreadsheet to parse excel files with multiple sheets. I am currently loading a file using the following code: excelFile.LoadXlsx(inputExcel, XlsxOptions.None); where inputExcel is a fullpath. After importing the excel, I try to…
user2399378
  • 829
  • 2
  • 10
  • 23
1
vote
2 answers

GemBox - scroll into view functionality missing?

I'm working with GemBox (version 3.5) for the first time and have one problem. When opening a generated XLSX file, it is always scrolled to the bottom of the worksheet. I (or, rather, my customer) want it to start out at the top left position. Is…
peter3
  • 1,074
  • 13
  • 22
1
vote
3 answers

C# GemBox Excel Import Error

I am trying to import an excel file into a data table using GemBox and I keep getting this error: Invalid data value when extracting to DataTable at SourceRowIndex: 1, and SourceColumnIndex: 1. As far as I can tell my code is correct and my file is…
Nathan
  • 5,059
  • 16
  • 48
  • 61
1
vote
0 answers

something other than gembox.spreadsheet with asp.net

Had a wee go at using gembox.spreadsheet to read an excel doc from asp.net, nice package but too expensive Anyone know of any other software like that that isn't expensive and does the same job?
John
  • 3,965
  • 21
  • 77
  • 163
1
vote
1 answer

Conversion of Special characters from MS-Word or Open Office writer to Notepad

I have a string and I am using GEMBOX SPREADSHEET string sr = “Save as type”; In this -- Save as type -- is normal string but when i am loading a Text file Using GEMBOX this Symbol “Save as type” is Converted to �Save as type� How to solve…
Aravind
  • 177
  • 1
  • 3
  • 13
1
vote
2 answers

GemBox Spreadsheet : Multiple font colors in one cell

I'm exporting data using GemBox Spreadsheet and I need to format the text in a cell to have multiple colors. This is possible in Excel like this (found on StackOverflow): Dim fixedLength As Long fixedLength = Len("Employee") ActiveCell.FormulaR1C1 =…
SteveSDSL
  • 13
  • 3
0
votes
0 answers

How can I add checkbox to GemBox.spreadsheet excel in c#

I try this code, but FormControls not working! var workbook = new ExcelFile(); var worksheet = workbook.Worksheets.Add("Sheet 1"); var checkBox = worksheet.FormControls.AddCheckBox("Simple check box", "B2", 100, 15,…
0
votes
1 answer

C# Gembox Spreadsheet to populate comboBox

I am working on a program that uses comboboxes that are populated from a csv file, I initially just used streamreader to populate the combobox, but I was instructed to use gembox spreadsheet to populate it instead. Here is the streamreader code that…
0
votes
0 answers

C# Assigning numericUpDown value to a specific cell in Excel file

Heres what I have: if (int.TryParse(kit_csv_quantity.Text, out int kitOut)) { decimal kitOutValue = kitOut + kits_upDown.Value; kit_csv_quantity.Text = kitOutValue.ToString(); ItemLine IL =…
Csumner
  • 27
  • 5
0
votes
1 answer

is it possible to obtain the results of a custom validation?

Say I have a custom data validation setup like this for a cell in Excel: I then set the value of the cell in c# using Gembox Spreadsheet. At this point, is there a way to verify (from c#) if the validation linked to this cell was successful or…
Moe Sisko
  • 11,665
  • 8
  • 50
  • 80