1) There no method to verify if a row exist.
2) a NoSuchMethodError exception is a error which says that a method in
class not exist, it's no a program error.
3) all example which can be find in docs show the same structure that I
have.
But I find many same method into package. It depend of the sud-package
used.
Can anyone explain whar sub-package I must used ?
thanks
Stéphane
-----------------------------------
Stéphane PURNELLE [EMAIL PROTECTED]
Service Informatique Corman S.A. Tel : 00 32 087/342467
"Donahue, Michael" <[EMAIL PROTECTED]> a écrit sur 27/01/2006
16:58:29 :
> Is it possible that the first row is automatically created for you when
the
> worksheet is created? This probably isn't you issue since you appear to
be
> creating a new workbook, but one thing I've found is that you should
always
> check to see if a row or cell already exists before you try to create
it.
>
> There is a method on the HSSFSheet to check how many rows it has
associated
> with it, you might consider checking that.
>
> Hope this helps.
>
> - MJD
>
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Friday, January 27, 2006 9:10 AM
> To: POI Users List
> Subject: problem with createRow method
>
> Hi,
>
> JRE 1.5
>
> try {
> HSSFWorkbook wb = new HSSFWorkbook();
> HSSFSheet sheet = wb.createSheet("stock");
>
> ......
>
> for(i = 0; i < nbligne ; i++)
> {
> HSSFRow row = sheet.createRow((short)i);
> for(j = 0; j < taille_array; j++)
> {
> array[i][j] = " ";
> row.createCell((short)j);
> }
> }
>
> ........
> When I exec the class, I have :
>
> java.lang.NoSuchMethodError:
>
org.apache.poi.hssf.usermodel.HSSFSheet.createRow(S)Lorg/apache/poi/hssf/use
> rmodel/HSSFRow;
>
> What's happening ?
>
> Version : poi-2.5.1-final-20040804.jar
>
> thanks
>
> Stéphan
>
>
> -----------------------------------
> Stéphane PURNELLE [EMAIL PROTECTED]
> Service Informatique Corman S.A. Tel : 00 32 087/342467
>
****************************************************************************
> This email may contain confidential material.
> If you were not an intended recipient,
> Please notify the sender and delete all copies.
> We may monitor email to and from our network.
>
****************************************************************************