A
A
Anastasia2021-06-13 01:46:44
excel
Anastasia, 2021-06-13 01:46:44

How to insert two actions in one cell?

Hello. I have a table:
A - description
B - income
C - expense
D - total
Each row is a separate entry.
It cannot be that in one line there was both an income and an expense.

I have a problem with column D.

I need the total to be calculated automatically. The 2nd line (the first line with headers) contains the initial amount of money. Tell me, how can I write two operations at once in D: SUM (B3: D2) and MINUS (C3: D2)? So that on the next lines there will be addition and subtraction with the previous line?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Anastasia, 2021-06-14
@nastya97core

=ЕСЛИ(И(ЕПУСТО(C3);ЕПУСТО(D3));;E2+C3-D3)
If columns 2 and 3 are empty, then we do not write anything, and if not empty, then add 2 and subtract 3

G
Grigory Boev, 2021-06-13
@ProgrammerForever

Multiply consumption by -1
=СУММ(B3: D2)-СУММ(C3:D2)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question