Personal Finance Intelligence Dashboard
No sheet? Use demo@example.com / demo123
| Date | Description | Category | Income | Expense | Charity | Other |
|---|
Used to read data into the dashboard. Sheet must be shared as "Anyone with the link โ Viewer".
Used to write data from My Data back into your Google Sheet. Follow the setup steps below, then paste your Web App URL here.
Open the Google Sheet that is connected to this dashboard.
Delete everything in the editor and paste this exact code:
function doPost(e) {
try {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var params = JSON.parse(e.postData.contents);
var action = params.action;
var tab = params.tab;
var rows = params.rows;
var sheet = ss.getSheetByName(tab);
if (!sheet) {
return jsonResponse({ status: 'error', message: 'Tab not found: ' + tab });
}
if (action === 'replace') {
// Keep header row, clear data rows, write new data
var lastRow = sheet.getLastRow();
if (lastRow > 1) sheet.deleteRows(2, lastRow - 1);
if (rows && rows.length > 0) {
sheet.getRange(2, 1, rows.length, rows[0].length).setValues(rows);
}
}
return jsonResponse({ status: 'success', tab: tab, rowsWritten: rows ? rows.length : 0 });
} catch(err) {
return jsonResponse({ status: 'error', message: err.message });
}
}
function doGet(e) {
return jsonResponse({ status: 'ok', message: 'FinanceFlow Apps Script is running.' });
}
function jsonResponse(obj) {
return ContentService
.createTextOutput(JSON.stringify(obj))
.setMimeType(ContentService.MimeType.JSON);
}
Paste the Web App URL into the Google Apps Script field above and click Save. The URL looks like:
https://script.google.com/macros/s/AKfy.../exec
โ ๏ธ Every time you modify the script you must create a New Deployment โ redeploying does not update the URL.
Enter the license code provided to you. Your login email is used to validate the license.