• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Digital Answers

How to tech tutorials in simple words

  • Home
  • About Us
  • Disclaimer
  • Privacy Policy

Admin

How to enable autocomplete in Google Docs Spreadsheet

August 24, 2011 by Admin 5 Comments

Autocomplete feature helps users by automatically filling the content of cell when users starting entering the first couple of letters in the Cell. The automatic entry is picked from the previously entered values for the same column.

Let us say you have got the following list of entries in one of the column

Arizona
Alabama
California
Florida
Indiana

Now when you start typing Ar in the cell below Indiana, Spreadsheet will automatically display Arizona based on the entries done earlier for that column. And when you press enter this value will be automatically filled for that cell.

You can enable Autocomplete feature in Google Spreadsheet by clicking the Tools menu and selecting Enable AutoComplete from list of available menus.

Remember that if there is a empty cell before the active cell then Autocomplete feature will try to pick from the below column values.

Filed Under: Excel, Technical Tagged With: Autocomplete, Enable, Google, Google Docs, spreadsheet

Change alternate row background colors in Spreadsheet using Google Apps Script

August 22, 2011 by Admin 8 Comments

Here is a Google Apps Script that would set the background color of alternate rows in Google Spreadsheet. This script would set the background color of of the selection, this may not be an efficient script but would do the job.

Let us take the following sample data which will be used by the script for setting the background color.

Install the below script and select the data by excluding the Header columns and execute the script.

function alternateColor() {
  var totalRows = SpreadsheetApp.getActiveRange().getNumRows();
  var totalColumns = SpreadsheetApp.getActiveRange().getNumColumns();
  var startRow = SpreadsheetApp.getActiveRange().getRow();
  var startColumn = SpreadsheetApp.getActiveRange().getColumn();
  var sheet = SpreadsheetApp.getActiveSheet();
  var row = startRow;
  while (row < totalRows+startRow)
  {
    var column = startColumn
    while (column < totalColumns+startColumn){
      if(row%2 == 0){
           sheet.getRange(row, column).setBackgroundColor(“lightgrey”);
      }
      column++;
  }
    row++;
  }
}

After executing the script, the sample data would look as shown below.

If you want to change the white color then you can add an else statement to set the background color for odd row numbers as well.

if(row%2 == 0){
           sheet.getRange(row, column).setBackgroundColor(“lightgrey”);
      } else {
          sheet.getRange(row, column).setBackgroundColor(“lightblue”);
}

Let me know if any one have a better suggestionn.

Filed Under: Excel, Technical Tagged With: Alternate rows, Google Apps Script, spreadsheet

  • « Go to Previous Page
  • Go to page 1
  • Interim pages omitted …
  • Go to page 7
  • Go to page 8
  • Go to page 9

Primary Sidebar

Recent Posts

  • Disable conversion of two numbers with dash as date in Excel
  • How to Protect Formulas in Excel
  • How to Change the Default Font in Excel
  • How to Add Country Code to Phone Automatically in Excel
  • How to Insert Pictures in Excel

blogmines.com Copyright © 2023