Questions tagged [npoi]

.NET version of the Apache POI (Java) project

This project is the .NET version of the Apache POI project (the Java API for Microsoft Documents). POI is an open source project which can help you read/write xls, doc, and ppt files, so it has wide applications. For example, you can use it to generate an Excel report without Microsoft Office suite installed on your server and it is more efficient than calling Microsoft Excel ActiveX in the background; you can also use it to extract text from Office documents to help you implement full-text indexing feature (most of time this feature is used to create search engines).

Latest stable version: 2.6.0 / 17 November 2022

Latest actual source code: https://github.com/nissl-lab/npoi

612 questions
0
votes
1 answer

npoi 'Sheet' type or namespace could not be found

This seems like a super simple issue to resolve. The type or namespace 'Sheet' is simply not there, so I get the red underline with the above message. I have included: using NPOI.HSSF.UserModel; using NPOI.HPSF; using NPOI.POIFS.FileSystem; using…
miniparser
  • 107
  • 1
  • 6
0
votes
1 answer

NPOI writing XLS file converting to Azure Blob

I'm trying to convert current application that uses NPOI for creating xls document on the server to Azure hosted application. I have little experience with NPOI and Azure so 2 strikes right there. I have the app uploading the xls to Blob container…
Marc
  • 1
  • 1
0
votes
0 answers

Parallel Linq Optimization with SelectMany

I'm scanning and transforming several hundred thousand Excel workbooks each with variable number of worksheets. I'm taking a PLINQ query on the array of workbook file names, opening each workbook using NPOI, enumerating the worksheets, flattening…
Alton XL
  • 635
  • 6
  • 18
0
votes
1 answer

How to create word report using NPOI API in .net

I want to use NPOI to generate word report based on ".dot" template, but I didn't find any documentation to do that. Can someone help me?
0
votes
1 answer

Get the left and the top value for a excel cell

In my project, I use the .NET library npoi to create some Excel documents. If MS Office is installed, checkboxes and a combobox with the MS interop Excel DLL will be added. Because different Excel sheets will be created with different column…
KraemerS
  • 51
  • 7
0
votes
1 answer

NPOI: Convert Xlsm to Xlsx

I'm writing a program to process some excel documents, the program is written in C# in Visual Studio 2010, and I'm using the NPOI library. I notice the I was not able to use CloneSheet() for the xlsm file, but I was able to do so with…
sora0419
  • 2,308
  • 9
  • 39
  • 58
0
votes
1 answer

NPOI : how to read excel cell which having no header

I am trying to extract TEXT from a .xlsx Excel file using NPOI. Below is the link of sample Excel file: http://s29.postimg.org/i7rtrucaf/excel_File.png The function ExcelDocumentToText extracts all the cell values, but not the cell which contains…
0
votes
1 answer

Read Excel Cell Format

I'm working on this program that will read the data in excel file and put it into our database. The program is written in Visual Studio 2010 using C#, and I'm using the NPOI library. In the past, I was able to read the spreadsheet row by row and…
sora0419
  • 2,308
  • 9
  • 39
  • 58
0
votes
1 answer

C# NPOI and sheet scale: how to set "scaling mode"?

I'm using NPOI 1.2.5 with C# to generate some worksheet. I need to set my sheet "Scaling mode" to "Reduce/enlarge printout" (see the last option of this LibreOffice screenshot) No matter how hard I try, my generated sheet always have "Fit print…
0
votes
1 answer

NPOI's MemoryStream object into iTextSharp?

I have created a Excel in MemoryStream from NPOI. The NPOI code: Dim oFile As New FileStream(Path:=context.Server.MapPath("./Test.xls"), mode:=FileMode.Open) Dim wb As New HSSFWorkbook(oFile) Dim ms As New MemoryStream Dim sheet As HSSFSheet =…
0
votes
1 answer

NPOI for Excel file writing

I am using NPOI for writing some contents to a excel file.For some contents I have no issues in writing them to a cell but there are some contents like below "Continuous Arithmetic Operation in the statement…
Pravin K
  • 311
  • 2
  • 6
  • 19
0
votes
0 answers

unity how to use NPOI on mobile?

I have written code on Unity3d window, it's working perfectly. But when I switch platform to ios, it doesn't work. I want to know if it works on ios mobile or not? Why doesn't it work? Does anyone know how to fix it? using System; using…
Kang Hoo
  • 1
  • 2
0
votes
5 answers

Opening .xlsx Files In Npoi

I am trying to open an .xlsx file using Npoi but it keeps crashing with the following error: 1 is not a supported code page. Parameter name: codepage My code is very simple: OpenFileDialog ofd = new OpenFileDialog(); ofd.Filter = "Excel…
TheGateKeeper
  • 4,420
  • 19
  • 66
  • 101
0
votes
1 answer

Cannot convert workbook to sheet in NPOI

I use NPOI 2.0.1 beta to import excel(xlsx) data to GridView . Firstly , using this link , convert xlsx Worksheet format to xls Worksheet . But , at the following line , it's show me error . HSSFWorkbook workbook = new HSSFWorkbook(); MemoryStream…
zey
  • 5,939
  • 14
  • 56
  • 110
0
votes
1 answer

How to read(import) text from a .doc file using NPOI for .net

I am trying to do something so simple but I can not find a way for doing it.I have viewed the NPOI site few times but they have all kind of problem solvings except mine.I just want to load a .doc(MS Office Word 97-2003) document and get its text and…
user2128702
  • 2,059
  • 2
  • 29
  • 74