I'm going to give you a couple working scripts that you created for me that I want to modify.  First for the category prompt menu, in addition to submit, can we add another button to skip a transaction.  The reason for this is that the user may want to split the transaction manually across different categories.  This means that in the transactions worksheet, you should leave the transaction that has been skipped blank.  here is the categoryprompt.html code: <!DOCTYPE html>
<html>
  <head>
    <base target="_top">
    <style>
      body {
        font-family: Arial, sans-serif;
        padding: 20px;
      }
      .transaction-details {
        margin-bottom: 20px;
      }
      .transaction-details p {
        margin: 5px 0;
      }
      .category-selection {
        margin-bottom: 20px;
      }
      .actions {
        text-align: right;
      }
      .actions button {
        margin-left: 10px;
        padding: 8px 16px;
        font-size: 14px;
        cursor: pointer;
      }
    </style>
  </head>
  <body>
    <div class="transaction-details">
      <h3>Transaction Details:</h3>
      <p><strong>Date:</strong> <span id="date"></span></p>
      <p><strong>Description:</strong> <span id="description"></span></p>
      <p><strong>Amount:</strong> $<span id="amount"></span></p>
    </div>
    <div class="category-selection">
      <label for="category"><strong>Select Category:</strong></label><br>
      <select id="category">
        <option value="" disabled selected>Select a category</option>
        <? for (var i = 0; i < CATEGORIES.length; i++) { ?>
          <option value="<?= CATEGORIES[i] ?>"><?= CATEGORIES[i] ?></option>
        <? } ?>
      </select>
    </div>
    <div class="actions">
      <button id="cancelButton" onclick="handleCancel()">Cancel</button>
      <button id="submitButton" onclick="handleSubmit()">Submit</button>
    </div>
    
    <script>
      /**
       * Sets the transaction details in the dialog.
       * @param {Object} details - The transaction details.
       */
      function setTransactionDetails(details) {
        document.getElementById('date').innerText = details.date;
        document.getElementById('description').innerText = details.description;
        document.getElementById('amount').innerText = details.amount;
      }

      /**
       * Handles the submission of the selected category.
       */
      function handleSubmit() {
        var select = document.getElementById('category');
        var selectedCategory = select.value;
        if (selectedCategory === "") {
          alert("Please select a category before submitting.");
          return;
        }
        
        // Disable inputs to prevent multiple submissions
        document.getElementById('submitButton').disabled = true;
        document.getElementById('cancelButton').disabled = true;
        document.getElementById('category').disabled = true;
        
        // Call the server-side function to process the selected category
        google.script.run
          .withSuccessHandler(function(moreTransactions) {
            if (moreTransactions) {
              // Fetch the next transaction details
              google.script.run
                .withSuccessHandler(function(details) {
                  if (details.date) {
                    // Update the transaction details
                    setTransactionDetails(details);
                    // Reset the dropdown and enable inputs
                    document.getElementById('category').value = "";
                    document.getElementById('category').disabled = false;
                    document.getElementById('submitButton').disabled = false;
                    document.getElementById('cancelButton').disabled = false;
                  } else {
                    // No more transactions, notify the user and close the dialog
                    alert("All transactions have been processed.");
                    google.script.host.close();
                  }
                })
                .getCurrentTransactionDetails();
            } else {
              // No more transactions, notify the user and close the dialog
              alert("All transactions have been processed.");
              google.script.host.close();
            }
          })
          .handleCategorySelection(selectedCategory);
      }

      /**
       * Handles the cancellation of the categorization process.
       */
      function handleCancel() {
        if (confirm("Are you sure you want to cancel the categorization process?")) {
          google.script.host.close();
        }
      }

      /**
       * Initializes the dialog by fetching and displaying the current transaction details.
       */
      function initializeDialog() {
        google.script.run
          .withSuccessHandler(setTransactionDetails)
          .getCurrentTransactionDetails();
      }

      // Initialize the dialog when the window loads
      window.onload = initializeDialog;
    </script>
  </body>
</html>    and here is the main code code.gs.gs:  // Define the list of categories
const CATEGORIES = [
  "Revenue",
  "Donations",
  "House",
  "Food",
  "Auto",
  "Debts",
  "E&R",
  "Clothes",
  "Investments",
  "Health care",
  "Life & disability Insurance",
  "Misc"
];

/**
 * Main function to initiate the categorization process.
 */
function importAndCategorizeTransactions() {
  var ss = SpreadsheetApp.getActiveSpreadsheet();
  var transactionsSheet = ss.getSheetByName("Transactions");
  var expensesSheet = ss.getSheetByName("Expenses");
  
  // Validate Sheet Existence
  if (!transactionsSheet) {
    SpreadsheetApp.getUi().alert("The 'Transactions' sheet does not exist.");
    return;
  }
  
  if (!expensesSheet) {
    SpreadsheetApp.getUi().alert("The 'Expenses' sheet does not exist.");
    return;
  }

  // Define Constants
  var TRANSACTION_START_ROW = 2; // Transactions start at Row 2
  var EXPENSES_START_ROW = 6;    // Expenses data starts at Row 6
  var PROCESSED_COLUMN = 4;      // Column D (1-based index)

  // Check if 'Processed' header exists; if not, add it
  var processedHeader = transactionsSheet.getRange(1, PROCESSED_COLUMN).getValue(); // Row 1, Column D
  if (processedHeader.toString().trim().toUpperCase() !== "PROCESSED") {
    transactionsSheet.getRange(1, PROCESSED_COLUMN).setValue("Processed");
    Logger.log("'Processed' header added to 'Transactions' sheet.");
  }

  // Fetch Transactions Data (Columns A-C and D)
  var lastTransactionRow = transactionsSheet.getLastRow();
  if (lastTransactionRow < TRANSACTION_START_ROW) {
    SpreadsheetApp.getUi().alert("No transactions found to process.");
    Logger.log("No transactions found to process.");
    return;
  }
  
  // Fetch data from Columns A-C and D (Processed)
  var transactionDataRange = transactionsSheet.getRange(TRANSACTION_START_ROW, 1, lastTransactionRow - TRANSACTION_START_ROW + 1, PROCESSED_COLUMN);
  var transactionsData = transactionDataRange.getValues();
  
  // Create Category to Column Mapping using CATEGORIES constant
  var categoryMap = {};
  for (var i = 0; i < CATEGORIES.length; i++) {
    var categoryOriginal = CATEGORIES[i].trim();
    var categoryKey = categoryOriginal.toUpperCase();
    categoryMap[categoryKey] = { column: i + 5, name: categoryOriginal }; // Columns E onwards (5th column)
  }
  
  // Optional: Log the category map for debugging
  Logger.log("Category Map: " + JSON.stringify(categoryMap));
  
  // Store Necessary Data in Script Properties for Access in HTML Dialog
  var props = PropertiesService.getScriptProperties();
  props.setProperty("TRANSACTION_START_ROW", TRANSACTION_START_ROW);
  props.setProperty("PROCESSED_COLUMN", PROCESSED_COLUMN);
  props.setProperty("EXPENSES_START_ROW", EXPENSES_START_ROW);
  
  // Store all transactions data in properties as JSON
  props.setProperty("TRANSACTIONS_DATA", JSON.stringify({
    transactions: transactionsData,
    lastRow: lastTransactionRow
  }));
  
  // Store categoryMap in properties as JSON
  props.setProperty("CATEGORY_MAP", JSON.stringify(categoryMap));
  
  // Store ExpensesSheet name to access it later
  props.setProperty("EXPENSES_SHEET_NAME", expensesSheet.getName());
  
  Logger.log("Stored transaction data and category map in Script Properties.");
  
  // Open the categorization dialog
  showCategorizationDialog();
}

/**
 * Function to display the custom categorization dialog.
 */
function showCategorizationDialog() {
  // Create a template from the HTML file
  var template = HtmlService.createTemplateFromFile('CategoryPrompt');
  
  // Pass the CATEGORIES array to the template
  template.CATEGORIES = CATEGORIES;
  
  // Evaluate the template and set dimensions
  var html = template.evaluate()
    .setWidth(400)
    .setHeight(300);
  
  // Show the modal dialog
  SpreadsheetApp.getUi().showModalDialog(html, 'Categorize Transactions');
}

/**
 * Function to process the selected category and mark the transaction as processed.
 * Returns a boolean indicating whether more transactions remain.
 * @param {string} categorySelected - The category selected by the user.
 * @return {boolean} - True if there are more transactions to process, false otherwise.
 */
function handleCategorySelection(categorySelected) {
  Logger.log("Selected Category: " + categorySelected);
  return processCategory(categorySelected);
}

/**
 * Processes the selected category for the current transaction.
 * @param {string} categorySelected - The category selected by the user.
 * @return {boolean} - True if there are more transactions to process, false otherwise.
 */
function processCategory(categorySelected) {
  var ss = SpreadsheetApp.getActiveSpreadsheet();
  var transactionsSheet = ss.getSheetByName("Transactions");
  var expensesSheetName = PropertiesService.getScriptProperties().getProperty("EXPENSES_SHEET_NAME");
  var expensesSheet = ss.getSheetByName(expensesSheetName);
  
  var TRANSACTION_START_ROW = parseInt(PropertiesService.getScriptProperties().getProperty("TRANSACTION_START_ROW"), 10);
  var PROCESSED_COLUMN = parseInt(PropertiesService.getScriptProperties().getProperty("PROCESSED_COLUMN"), 10);
  var EXPENSES_START_ROW = parseInt(PropertiesService.getScriptProperties().getProperty("EXPENSES_START_ROW"), 10);
  
  var transactionsData = JSON.parse(PropertiesService.getScriptProperties().getProperty("TRANSACTIONS_DATA"));
  var categoryMap = JSON.parse(PropertiesService.getScriptProperties().getProperty("CATEGORY_MAP"));
  
  // Find the next unprocessed transaction
  var transactionIndex = -1;
  for (var i = 0; i < transactionsData.transactions.length; i++) {
    var processed = transactionsData.transactions[i][PROCESSED_COLUMN - 1];
    if (!processed || processed.toString().trim() === "") {
      transactionIndex = i;
      break;
    }
  }
  
  if (transactionIndex === -1) {
    // All transactions processed
    SpreadsheetApp.getUi().alert("All transactions have been processed and categorized successfully.");
    // Cleanup Script Properties
    PropertiesService.getScriptProperties().deleteAllProperties();
    Logger.log("All transactions processed. Cleared Script Properties.");
    return false; // No more transactions
  }
  
  var row = transactionsData.transactions[transactionIndex];
  
  // Extract Transaction Details
  var transactionDateRaw = row[0]; // Column A
  var transactionDesc = row[1];     // Column B
  var transactionAmount = row[2];   // Column C
  
  // Parse Date to Extract Day
  var transactionDay = extractDay(transactionDateRaw);
  
  if (transactionDay === null) {
    SpreadsheetApp.getUi().alert("Unable to parse date in 'Transactions' sheet at row " + (TRANSACTION_START_ROW + transactionIndex) + ". Skipping this transaction.");
    // Mark as processed with "Error" to avoid repeated alerts
    transactionsSheet.getRange(TRANSACTION_START_ROW + transactionIndex, PROCESSED_COLUMN).setValue("Error");
    // Update transactionsData
    transactionsData.transactions[transactionIndex][PROCESSED_COLUMN - 1] = "Error";
    PropertiesService.getScriptProperties().setProperty("TRANSACTIONS_DATA", JSON.stringify(transactionsData));
    Logger.log("Transaction at index " + transactionIndex + " marked as Error due to date parsing.");
    // Proceed to the next transaction
    return processCategory(categorySelected);
  }
  
  // Validate Day
  if (transactionDay < 1 || transactionDay > 31) {
    SpreadsheetApp.getUi().alert("Invalid day (" + transactionDay + ") extracted from date in 'Transactions' sheet at row " + (TRANSACTION_START_ROW + transactionIndex) + ". Skipping this transaction.");
    // Mark as processed with "Error" to avoid repeated alerts
    transactionsSheet.getRange(TRANSACTION_START_ROW + transactionIndex, PROCESSED_COLUMN).setValue("Error");
    // Update transactionsData
    transactionsData.transactions[transactionIndex][PROCESSED_COLUMN - 1] = "Error";
    PropertiesService.getScriptProperties().setProperty("TRANSACTIONS_DATA", JSON.stringify(transactionsData));
    Logger.log("Transaction at index " + transactionIndex + " marked as Error due to invalid day.");
    // Proceed to the next transaction
    return processCategory(categorySelected);
  }
  
  // Validate Selected Category
  var categoryKey = categorySelected.toUpperCase();
  if (!categoryMap.hasOwnProperty(categoryKey)) {
    SpreadsheetApp.getUi().alert("Selected category '" + categorySelected + "' is invalid. Please try again.");
    Logger.log("Invalid category selected: " + categorySelected);
    // Do not mark as processed; user can retry
    return true; // Assume there are more transactions to process
  }
  
  var categoryData = categoryMap[categoryKey];
  var categoryColumn = categoryData.column;
  var categoryName = categoryData.name;
  
  // Locate Row in Expenses Sheet Based on Day
  var expensesLastRow = expensesSheet.getLastRow();
  var dayRow = -1;
  
  // Assuming Dates (1-31) are in Column A starting from Row 6
  var dateColumnRange = expensesSheet.getRange(EXPENSES_START_ROW, 1, expensesLastRow - EXPENSES_START_ROW + 1, 1);
  var dateValues = dateColumnRange.getValues();
  
  for (var r = 0; r < dateValues.length; r++) {
    var cellDay = dateValues[r][0];
    if (cellDay === transactionDay) {
      dayRow = EXPENSES_START_ROW + r;
      break;
    }
  }
  
  if (dayRow === -1) {
    SpreadsheetApp.getUi().alert("No matching day (" + transactionDay + ") found in 'Expenses' sheet for transaction at row " + (TRANSACTION_START_ROW + transactionIndex) + ". Skipping this transaction.");
    // Mark as processed with "Error" to skip this transaction
    transactionsSheet.getRange(TRANSACTION_START_ROW + transactionIndex, PROCESSED_COLUMN).setValue("Error");
    // Update transactionsData
    transactionsData.transactions[transactionIndex][PROCESSED_COLUMN - 1] = "Error";
    PropertiesService.getScriptProperties().setProperty("TRANSACTIONS_DATA", JSON.stringify(transactionsData));
    Logger.log("Transaction at index " + transactionIndex + " marked as Error due to missing day in Expenses.");
    // Proceed to the next transaction
    return processCategory(categorySelected);
  }
  
  // Prepare Transaction Entry (Only Amount)
  var transactionAmountValue = parseFloat(transactionAmount).toFixed(2); // e.g., "150.00" or "-75.50"
  var numericAmount = parseFloat(transactionAmountValue); // Convert to number: 150.00 or -75.50
  
  // Fetch Existing Cell Value in Expenses Sheet
  var targetCell = expensesSheet.getRange(dayRow, categoryColumn);
  var existingValue = targetCell.getValue();
  
  var newTotal = numericAmount;
  
  if (typeof existingValue === 'number') {
    newTotal = existingValue + numericAmount;
  } else if (typeof existingValue === 'string') {
    // Attempt to parse all amounts if stored as text entries
    // Example: "$50.00\n$25.00"
    var amountLines = existingValue.split('\n');
    var sumExisting = 0;
    for (var j = 0; j < amountLines.length; j++) {
      // Extract numerical value from each line
      var amt = parseFloat(amountLines[j].replace(/[^-\d\.]/g, ''));
      if (!isNaN(amt)) {
        sumExisting += amt;
      }
    }
    newTotal = sumExisting + numericAmount;
  }
  // Else (empty or other types), newTotal remains as numericAmount
  
  // Round to two decimal places to avoid floating point issues
  newTotal = Math.round((newTotal + Number.EPSILON) * 100) / 100;
  
  // Set the new total back to the Expenses sheet
  // Assumes the cell is formatted as Currency or Number
  targetCell.setValue(newTotal);
  targetCell.setNumberFormat("$#,##0.00"); // Optional: Ensures currency format
  
  // Mark Transaction as Processed with Category Name
  transactionsSheet.getRange(TRANSACTION_START_ROW + transactionIndex, PROCESSED_COLUMN).setValue(categoryName);
  
  // Update transactionsData in Script Properties
  transactionsData.transactions[transactionIndex][PROCESSED_COLUMN - 1] = categoryName;
  PropertiesService.getScriptProperties().setProperty("TRANSACTIONS_DATA", JSON.stringify(transactionsData));
  
  Logger.log("Processed transaction at index " + transactionIndex + " with category: " + categoryName);
  
  // Check if there are more transactions to process
  var moreTransactions = false;
  for (var i = transactionIndex + 1; i < transactionsData.transactions.length; i++) {
    var processed = transactionsData.transactions[i][PROCESSED_COLUMN - 1];
    if (!processed || processed.toString().trim() === "") {
      moreTransactions = true;
      break;
    }
  }
  
  return moreTransactions;
}

/**
 * Extracts the day from a date input, ignoring the month.
 * @param {string|Date} dateInput - The date input which can be a Date object or a string.
 * @return {number|null} - Returns the day as a number (1-31) or null if parsing fails.
 */
function extractDay(dateInput) {
  if (dateInput instanceof Date) {
    return dateInput.getDate();
  } else if (typeof dateInput === 'string') {
    // Attempt to parse the day from the string
    // Assuming formats like "Dec-01", "2023-12-01", "12/01/2023", etc.
    var parsedDate = new Date(dateInput);
    if (!isNaN(parsedDate)) {
      return parsedDate.getDate();
    } else {
      // If parsing fails, attempt to extract the day manually
      var dayMatch = dateInput.match(/(\d{1,2})$/);
      if (dayMatch && dayMatch[1]) {
        var day = parseInt(dayMatch[1], 10);
        if (!isNaN(day) && day >= 1 && day <= 31) {
          return day;
        }
      }
    }
  }
  return null; // Failed to parse day
}

/**
 * Formats the date input into a readable string.
 * @param {string|Date} dateInput - The date input which can be a Date object or a string.
 * @return {string} - Returns the formatted date string.
 */
function formatDate(dateInput) {
  if (dateInput instanceof Date) {
    return Utilities.formatDate(dateInput, Session.getScriptTimeZone(), "EEE MMM dd yyyy");
  } else if (typeof dateInput === 'string') {
    var parsedDate = new Date(dateInput);
    if (!isNaN(parsedDate)) {
      return Utilities.formatDate(parsedDate, Session.getScriptTimeZone(), "EEE MMM dd yyyy");
    } else {
      return dateInput; // Return as-is if unable to parse
    }
  }
  return "";
}

/**
 * Retrieves the current transaction details to display in the HTML dialog.
 * @return {Object} - An object containing date, description, and amount.
 */
function getCurrentTransactionDetails() {
  var props = PropertiesService.getScriptProperties();
  var transactionsData = JSON.parse(props.getProperty("TRANSACTIONS_DATA"));
  var TRANSACTION_START_ROW = parseInt(props.getProperty("TRANSACTION_START_ROW"), 10);
  var PROCESSED_COLUMN = parseInt(props.getProperty("PROCESSED_COLUMN"), 10);
  
  // Find the first unprocessed transaction
  for (var i = 0; i < transactionsData.transactions.length; i++) {
    var row = transactionsData.transactions[i];
    var processed = row[PROCESSED_COLUMN - 1];
    if (!processed || processed.toString().trim() === "") {
      var transactionDateRaw = row[0]; // Column A
      var transactionDesc = row[1];     // Column B
      var transactionAmount = row[2];   // Column C
      
      // Format the date
      var formattedDate = formatDate(transactionDateRaw);
      
      Logger.log("Fetching transaction at index: " + i);
      
      return {
        date: formattedDate,
        description: transactionDesc,
        amount: parseFloat(transactionAmount).toFixed(2)
      };
    }
  }
  
  // If no unprocessed transactions are found
  Logger.log("No unprocessed transactions found.");
  return {};
}

/**
 * Adds a custom menu to the Google Sheets UI upon opening the spreadsheet.
 */
function onOpen() {
  var ui = SpreadsheetApp.getUi();
  ui.createMenu('Transaction Tools')
    .addItem('Import & Categorize Transactions', 'importAndCategorizeTransactions')
    .addToUi();
}