[Solved] Subtract B1 from last entry in column C

Discuss the spreadsheet application
Post Reply
cattlelyst
Posts: 7
Joined: Fri Mar 22, 2024 10:09 pm

[Solved] Subtract B1 from last entry in column C

Post by cattlelyst »

So i want to format cell TK to take the first entry from Cell B Which will always be B1 and add it to the last entry in cell C which isn't always the last line can this be done?

 Edit: Changed subject, was How to format cell to take from one line and add to another 
Make your post understandable by others 
-- MrProgrammer, forum moderator 
Last edited by MrProgrammer on Sat Mar 23, 2024 4:20 am, edited 2 times in total.
Reason: Edited topic's subject
Openoffice 4.6.3 on Windows 11
FJCC
Moderator
Posts: 9283
Joined: Sat Nov 08, 2008 8:08 pm
Location: Colorado, USA

Re: How to format cell to take from one line and add to another

Post by FJCC »

It isn't clear to me what you want to do. Please upload a small example file explaining which cells you want to add and where you want the result to appear. To upload a file, click Post Reply and look for the Attachments tab just below the box where you type a response.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
cattlelyst
Posts: 7
Joined: Fri Mar 22, 2024 10:09 pm

Re: How to format cell to take from one line and add to another

Post by cattlelyst »

Example.png
Example.png (105.59 KiB) Viewed 1174 times
I hope you can see this
So i want the red to equal the orange (constant Always b1) + the last line in the purple (which ever C comes last)
Openoffice 4.6.3 on Windows 11
cattlelyst
Posts: 7
Joined: Fri Mar 22, 2024 10:09 pm

Re: How to format cell to take from one line and add to another

Post by cattlelyst »

I am making a Monthly template
So this is March for Example but this time purple is at line 22
But Februrary the last entry is line 23
Attachments
example2-min.png
example2-min.png (34.19 KiB) Viewed 1168 times
Openoffice 4.6.3 on Windows 11
cattlelyst
Posts: 7
Joined: Fri Mar 22, 2024 10:09 pm

Re: How to format cell to take from one line and add to another

Post by cattlelyst »

So to recap Red must equal what ever B1 (orange) is plus what ever the last line in C (purple) is
Openoffice 4.6.3 on Windows 11
cattlelyst
Posts: 7
Joined: Fri Mar 22, 2024 10:09 pm

Re: How to format cell to take from one line and add to another

Post by cattlelyst »

Sorry I stand corrected lol Red Must equal Purple ( last line in C) minus Orange (First line in B)
Openoffice 4.6.3 on Windows 11
FJCC
Moderator
Posts: 9283
Joined: Sat Nov 08, 2008 8:08 pm
Location: Colorado, USA

Re: How to format cell to take from one line and add to another

Post by FJCC »

If all the cells in column C are filled until the one you want, you can use

Code: Select all

=INDEX(C1:C100;COUNT(C1:C100)) - B1
Edit: And all the cells after the one your want are empty until the end of the range C1:C100. Of course you can adjust C1:C100 to fit your needs.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
cattlelyst
Posts: 7
Joined: Fri Mar 22, 2024 10:09 pm

Re: How to format cell to take from one line and add to another

Post by cattlelyst »

awesome thank you so much
Openoffice 4.6.3 on Windows 11
cattlelyst
Posts: 7
Joined: Fri Mar 22, 2024 10:09 pm

Re: How to format cell to take from one line and add to another

Post by cattlelyst »

that will work perfect
I'm digitizing my Ledger for work for Kilometers driven for work vs Kilometers driven for personal and I want my year end to be as simple as possible and that formula makes it so.
saved to my template you're my hero
Openoffice 4.6.3 on Windows 11
Post Reply