This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Error in POI

 
nick sharma
Greenhorn
Posts: 28
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I used the Apache POI to access excel files.The example file given at the location
POI example
It contains the following lines of code which are generating a error


The error generated is that the above method does not exist in the package
org.apache.poi.hssf.usermodel.HSSFSheet

i have imported all the classes mentioned in the program and followed everything that was required by setting classpath to the jar files downloaded from the Apache site.

How do i solve the above problem.

Thank you
 
Rob Spoor
Sheriff
Pie
Posts: 20380
45
Chrome Eclipse IDE Java Windows
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Call a different method: that method simply does NOT exist in the API. Where did you get it from??
Try getRow or createRow - those are the only ones that return a HSSFRow.

The only methods that start with "getPhysical" are the following:
org.apache.poi.hssf.record.aggregates.ValueRecordsAggregate#getPhysicalNumberOfCells()
org.apache.poi.hssf.usermodel.HSSFRow#getPhysicalNumberOfCells()
org.apache.poi.hssf.record.aggregates.RowRecordsAggregate#getPhysicalNumberOfRows()
org.apache.poi.hssf.usermodel.HSSFSheet#getPhysicalNumberOfRows()
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic