Quantcast
Channel: Hot Weekly Questions - Web Applications Stack Exchange
Viewing all articles
Browse latest Browse all 9782

Creating a Custom Script for Google Sheets [closed]

$
0
0

I have a google sheet where I list values in a column and have them summed at the top (using =sum() formula). I would like to make a google apps script that automatically sums values and deletes them after adding them to the total. My goal is to eliminate the need for long columns of numbers and reduce this system so that I type in a single cell, the value is added to the total above that cell, and the cell is then emptied so I can add another value and repeat the process. Here is an image for explanation:

enter image description here

The left column is my current setup. I add additional numbers to the column and the total sum at the top will be updated (e.g. I will add 70 to the left column below 60 and the sum at the top will be updated to 280).

The right column is my desired setup with a script. I'd like to be able to type a number where the "type here" text is and have the value there added to the total and then deleted. This way I can keep adding values to the same cell instead of having very long columns of numbers. So for example, if I typed "70" in the cell with "type here" and hit return, the sum at the top would get updated to "280" and the "70" would be deleted so that the cell is blank again and the process can be repeated.

For clarification, I don't want there to be text present in the box where I'll be inputting numbers, this is just for explanation purposes.

I saw a very similar post but was unable to implement this script properly. Any help would be greatly appreciated :)


Viewing all articles
Browse latest Browse all 9782

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>