Just a thought from off of the top of my head - and I have not yet tried this
out - but what happens if yoi call the setAsActiveCell() method after you
create each sheet of the workbook?
The other alternative would be to create a workbook macro that gives cell A1
focus whenever the user selects a
Hello Mark and thank you for your reply,
I'm not exactly sure what you mean. Perhaps my case is a bit special
though. I use a base template that contains too many sheets. I then remove
sheets and modify them a bit. I also add a couple of sheets. However, most
sheets are not created by me (POI) but
Did you have a chance to see if showInPane() works Mark?
/Bengt
2015-09-24 17:20 GMT+02:00 Bengt Rodehav :
> Hello Mark and thank you for your reply,
>
> I'm not exactly sure what you mean. Perhaps my case is a bit special
> though. I use a base template that contains too many sheets. I then rem
If I am correct, showInPane() is not at all what you are after.
With Excel, it is possible to lock one or more rows/columns so that they
remain in view if the user scrolls through the contents of the worksheet.
One obvious use is when you place labels at the top of each column to show
what figures
Seems to work. I wrote and ran this to test the idea
import java.io.*;
import org.apache.poi.xssf.usermodel.*;
public class ActiveCellTest {
public static void main(String[] args) {
File file = null;
FileOutputStream fos = null;
BufferedOutputStream bos = null;
XSS
Hello Mark,
I am already using Sheet.setActiveCell() but it doesn't help. The cell
becomes selected but it is not in view.
My use case is a bit different. I read an existing Excel document which is
a template for the Excel document I create. The source Excel sometimes has
sheets that are scrolled
No answer off of the top of my head but let me play with a bit more code to
see what I can find out.
--
View this message in context:
http://apache-poi.1045710.n5.nabble.com/showInPane-does-not-work-tp5720321p5720386.html
Sent from the POI - User mailing list archive at Nabble.com.
---
Thanks - I appreciate it.
/Bengt
2015-09-29 9:06 GMT+02:00 Mark Beardsley :
> No answer off of the top of my head but let me play with a bit more code to
> see what I can find out.
>
>
>
> --
> View this message in context:
> http://apache-poi.1045710.n5.nabble.com/showInPane-does-not-work-tp572
No time yet to experiment with code - some people do not seem to understand
what I mean when I say that I have retired - but what I did intend to test
was combiningg a call to setActiveCell() with showInPane() something like
this;
showInPane()
setActiveCell()
that really did ought to work in my o
No worries Mark - I'm happy with your help.
I do use both showInPane() and setActiveCell() but it doesn't work for me.
I'm doing it in the other order though - maybe that makes a difference?
/Bengt
2015-10-01 8:30 GMT+02:00 Mark Beardsley :
> No time yet to experiment with code - some people do
Now for the bad news; currently, the api does not provide the necessary
interface to set the value within the xml markup for the workbook to control
the view in the way you require.
During today, I have had the opportunity to dig around and experiment with
some code. By looking at the raw xml mark
Thanks a lot for your effort!
Yes, what you've found out does agree with the testing I've done. I've also
wondered why there is no setter for the topLeftCell which I also thought
would be what is required in this case.
Thanks for your help,
/Bengt
2015-10-03 16:02 GMT+02:00 Mark Beardsley :
>
Three days of rain and it is too wet to work in the reed beds. So, I have
been able to play and make some real progress. The code below will make sure
that cell A1 is both active and appears at the top leaft hand corner of the
worksheet 'window'.
import java.io.*;
import org.apache.poi.xssf.usermo
Thanks a lot - will try ASAP.
/Bengt
2015-10-07 15:38 GMT+02:00 Mark Beardsley :
> Three days of rain and it is too wet to work in the reed beds. So, I have
> been able to play and make some real progress. The code below will make
> sure
> that cell A1 is both active and appears at the top leaft
I've tried your code and it works perfectly for me - thanks.
/Bengt
2015-10-07 16:24 GMT+02:00 Bengt Rodehav :
> Thanks a lot - will try ASAP.
>
> /Bengt
>
> 2015-10-07 15:38 GMT+02:00 Mark Beardsley :
>
>> Three days of rain and it is too wet to work in the reed beds. So, I have
>> been able to
Thanks for letting me know and sorry again that it too so long. Might well
propose this as an enhance,ent to the api - maybe setTopLeftCell(Sttring
cellAddress).
--
View this message in context:
http://apache-poi.1045710.n5.nabble.com/showInPane-does-not-work-tp5720321p5720524.html
Sent from th
I think that's an excellent idea. I did this:
private void scrollTopLeft(XSSFSheet theSheet) {
CTWorksheet ctWorksheet = theSheet.getCTWorksheet();
CTSheetViews ctSheetViews = ctWorksheet.getSheetViews();
CTSheetView ctSheetView =
ctSheetViews.getSheetViewArray(ctSheetViews.sizeOfShe
To find out how to get at the sheet view, I dug around in the source for the
XSSFSheet class. That class already included code to get at the array of
sheet views from the worksheet and it simply assumed that the first element
in the array should be used. The only check on size was simply to make su
Thanks a lot Mark,
/Bengt
2015-10-10 8:56 GMT+02:00 Mark Beardsley :
> To find out how to get at the sheet view, I dug around in the source for
> the
> XSSFSheet class. That class already included code to get at the array of
> sheet views from the worksheet and it simply assumed that the first e
Dear Mark,
Please help me to resolve the below
I have the same scenario but now I am dealing with HSSF Workbook and HSSF
Sheet.
Do we have any workaround for HSSF instead of XSSF.
// First step is to get at the CTWorksheet bean underlying the worksheet.
ctWorksheet = sheet.getCTWork
Dear POI team and Mark,
Please help me out of that issue.
showInPane not working for HSSF.
BR,
ARUN
--
Sent from: http://apache-poi.1045710.n5.nabble.com/POI-User-f2280730.html
-
To unsubscribe, e-mail: user-unsubscr...@poi.a
Not working is a very broad statement, what is happening, what did you expect?
What does your code look like?
-Original Message-
From: arun.ka [mailto:thimsa...@gmail.com]
Sent: Wednesday, February 07, 2018 2:44 AM
To: user@poi.apache.org
Subject: Re: showInPane does not work
Dear POI
to:thimsa...@gmail.com]
> Sent: Wednesday, February 07, 2018 2:44 AM
> To: user@poi.apache.org
> Subject: Re: showInPane does not work
>
> Dear POI team and Mark,
>
> Please help me out of that issue.
> showInPane not working for HSSF.
>
> BR,
> ARUN
>
>
clearer now.
>
> Greetings,
> Markus
>
>
> 2018-02-07 13:27 GMT+01:00 Murphy, Mark :
>
>> Not working is a very broad statement, what is happening, what did you
>> expect? What does your code look like?
>>
>> -Original Message-----
>> From: arun.ka [ma
Dear POI Team,
I am very sorry for unclear post.
Let me explain the situation.
I have the template.xls, that consists of macro with freezed pane.
Steps,
1. Reading the xls file (template.xls) from Input directory path
2. Writing the contents to that xls file[value pasting process based on
biz.]
3.
Dear POI Team,
Sorry for asking again.
Any updates.
BR,
Arun
--
Sent from: http://apache-poi.1045710.n5.nabble.com/POI-User-f2280730.html
-
To unsubscribe, e-mail: user-unsubscr...@poi.apache.org
For additional commands, e-ma
26 matches
Mail list logo