
My ideal log is below.
Sep 10 ~USD (Extracted from H12 in spread sheet)
Sep 11 ~USD
Sep 12 ~USD
Please help me....
I know how to keep a log of constant but I don't know how to extract the value of a certain cell in GAS script and keep a log of it. enter image description here
This is the code.
const setDataLastRow = () => {
//シートを指定
const sheet = SpreadsheetApp.getActiveSheet();
//最終行を取得
const lastRow = sheet.getLastRow();
//今日の日付
const today = new Date();
//入力する内容
const contents = "Constant";
//スプレッドシートに入力するデータ
const inputData = [today, contents];
//入力する行
const inputCell = sheet.getRange(lastRow + 1, 1, 1, inputData.length);
//データの入力
inputCell.setValues([inputData]);
}