Ask Your Question
0

(CALC) Reference to the previous tab in same doc

asked 2018-01-19 15:47:03 +0200

ucancallmesimon gravatar image

Hey, Can I create a reference to the previous tab in Calc? I mean "comparatively". If I'm in tab_99 "prev" mean tab_98, if I'm in tab_45 it mean tab_48, etc

edit retag flag offensive close merge delete

Comments

Hello @ucancallmesimon,

Please specify:

  1. By "tab", do you mean the Sheet Tabs at the bottom of the window ?
  2. By "if I'm in tab_45 it mean tab_48", did you mean: "if I'm in tab_45 it mean tab_44" ?
librebel gravatar imagelibrebel ( 2018-01-19 17:53:29 +0200 )edit

2 Answers

Sort by » oldest newest most voted
0

answered 2018-01-19 20:49:34 +0200

Jim K gravatar image

updated 2018-01-19 20:50:31 +0200

Add @JohnSUN's SheetNamemacro from https://ask.libreoffice.org/en/questi... by going to Tools -> Macros -> Organize Macros -> LibreOffice Basic.

Then the following formula references cell A1 of the previous page.

=INDIRECT(SHEETNAME(SHEET()-1)&".A1")

Or this:

=INDIRECT(ADDRESS(1;1;4;1;SHEETNAME(SHEET()-1)))

Documentation: INDIRECT, ADDRESS, SHEET.

edit flag offensive delete link more
0

answered 2018-01-19 15:56:21 +0200

Yes; if you use relative reference (that is, sheet name without $), it will be relative - i.e., when you copy the cell with formula to another sheet, the formula will reference sheet that is "positioned" relatively to new cell like the one in original cell.

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2018-01-19 15:47:03 +0200

Seen: 274 times

Last updated: Jan 19 '18