Bug 14919 - HSSFSheet#getNumMergedRegions() throws NullPointerException
Summary: HSSFSheet#getNumMergedRegions() throws NullPointerException
Status: RESOLVED DUPLICATE of bug 13483
Alias: None
Product: POI
Classification: Unclassified
Component: HSSF (show other bugs)
Version: 2.0-dev
Hardware: Other other
: P3 minor (vote)
Target Milestone: ---
Assignee: POI Developers List
Depends on:
Reported: 2002-11-28 04:08 UTC by Toshiaki Kamoshida
Modified: 2004-11-16 19:05 UTC (History)
0 users


Note You need to log in before you can comment on or make changes to this bug.
Description Toshiaki Kamoshida 2002-11-28 04:08:44 UTC

When HSSFSheet instance is created by 
org.apache.poi.hssf.usermodel.HSSFSheet#createSheet(),instance field 
org.apache.poi.hssf.model.Sheet#marged is(not initialized correctry?) null,
calling HSSFSheet#getNumMergedRegions() and #getMergedRegionAt(int) throws 

I found it at 1.8.0dev.

Please try this code.
import org.apache.poi.hssf.usermodel.HSSFSheet;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;

public class POITest {
	public static void main(String args[]){
		HSSFWorkbook b = new HSSFWorkbook();
		HSSFSheet s = b.createSheet();

Thanks for each developer's good effort.
Comment 1 Toshiaki Kamoshida 2002-12-04 06:17:53 UTC
Sorry,this is a duplicate of bug No.13483.

*** This bug has been marked as a duplicate of 13483 ***