Calc: Exporting the excel sheet to pdf by command line(not using GUI) is exporting hidden pages

I am exporting the excel sheet to pdf, and pdf is containing the hidden sheets also.
I think this is due to the “Print Ranges”.
I have 4 sheets in the excel and all 4 sheets are added to “Print Ranges” and then I did hide for sheet 3 and 4.

Exporting to pdf is exporting all 4 sheets though sheets 3 and 4 are hidden.
when I clear the print Ranges it is exporting only sheet 1 and 2.

Is there any option to ignore print ranges when sheets are hidden ?

Regards,
Satya

Test.xlsx (9.2 KB)
Sample file attached.

Have you checked with older versions, such as bibisect repos, if the issue exists in them as well?

@ilmari I didn’t verify the bibisect repos. I don’t know if it is there from beginning or introudced somewhere later. But the problem is also there in 7.6.7.2 libre office

@ilmari I did bibisect repos (from 7.1 to 4.3) , the problem exists everywhere.

Select sheets 1 and 2, then export:
imagen

1 Like

@LeroyG I am not using GUI, I am exporting to pdf though headless commandline. In this case it is just 2 sheets to select but it may vary in real time. I wanted to export all the sheets except the hidden sheets using soffice --headless --convert-to pdf command line.

This (the info shared in your comment) must be in your question. Please, edit your question and paste this info there. Thanks.


Sorry that I don’t read carefully the title of your question (that say "by command line) and that I was not clear in my statement.

1 Like

And if I’m not wrong, the last configuration on GUI, it’s used with no GUI.

You are right if that is application level configuration change.
But this Print Rane->clear is particular to that excel sheet, so I want a way to clear it when exporting to pdf. I think, that is not possible.

PDF Export Command Line Parameters