I waited a while to see if anyone else replied to your post because I am
sorry to say that I cannot understand your question.
What do you mean by a subjoin please?
You talk of a problem with images but there does not seem to be any code
that works with images in your post. Further, the exception relates to the
addMergedRegion method and yet the code you have posted does not include a
call to this method. Can I ask you please to explain a little more clearly
exactly what you are trying to accomplish? Can you also post all of the code
you are trying to use - especially any that section that causes the
exception to be thrown. Finally, as fas as I am aware, the setSheetName()
method takes only two arguments, not three.
Yours
Mark B
saper1281 wrote:
>
> Help me, please.
> In the Exel document need to subjoin sheet 69.
> If in Exel document include image then Exel document return defective.
>
> When use poi-bin-3.5-beta5-20090219 return error:
> Exception in tread "main"
> java.lang.NoSuchMethodError:org.apache.poi.hssf.usermodel.HSSFSheet.addMergedRegion
> <Lorg/apache/poi/hssf/unit/Region;>I ......;
>
> When use poi-bin-3.2-FINAL-20081019 return defective document, error:
> Error initialization VBA(265), and appeal restore Exel document
>
>
> Code:
>
> HSSFWorkbook wb ;
> InputStream fileInput = null;
> try {
>
> fileInput = new FileInputStream(Pyt);
> POIFSFileSystem fs111= new POIFSFileSystem(new FileInputStream(Pyt));
> wb = new HSSFWorkbook(fs111);
> fileInput.close();
> }
> catch(Exception e){
> wb = new HSSFWorkbook();
> }
>
> HSSFSheet sheet =null;
>
> if(wb.getSheetIndex("sheet69")<0){
> sheet =wb.createSheet("sheet69");
> wb.setSheetName( wb.getSheetIndex("sheet69"), "sheet69",
> HSSFWorkbook.ENCODING_UTF_16 );
>
> }else
> {
> sheet=wb.getSheet("Лист69");
> }
>
> //----------
>
> //-----------
>
> OutputStream fileOut = new FileOutputStream(Pyt);
>
> wb.write(fileOut);
> fileOut.close();
>
>
--
View this message in context:
http://www.nabble.com/Images-and-Exel-tp23937543p23957498.html
Sent from the POI - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]