This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Retrieves all the rows in the active spreadsheet that contain data and logs the | |
* values for each row. | |
* For more information on using the Spreadsheet API, see | |
* https://developers.google.com/apps-script/service_spreadsheet | |
*/ | |
function readRows() { | |
var sheet = SpreadsheetApp.getActiveSheet(); | |
var rows = sheet.getDataRange(); | |
var numRows = rows.getNumRows(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script> | |
<script src="http://code.jquery.com/jquery-migrate-1.2.1.min.js"></script> | |
<script> | |
$(document).ready(function() { | |
getSheetData(); | |
}); | |
function getSheetData() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="myTest"></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<table id="statistics" class="table table-condensed table-striped"></table> | |
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css" /> | |
<script src="https://chriszarate.github.io/sheetrock/dist/sheetrock.min.js"></script> | |
<script> | |
var mySpreadsheet = 'https://docs.google.com/spreadsheets/d/1i_eJ1XyQXATMCanAZl55z_WAs_Lj0rad-lUnK7jhxz8/edit#gid=0'; | |
// Load an entire worksheet. | |
$('#statistics').sheetrock({ | |
url: mySpreadsheet |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ ['Name', 'Sum'], | |
['Max', 500], | |
['Lu', 150] ] | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getDataFromSheet() | |
{ | |
var sheet = SpreadsheetApp.getActiveSheet(); // get active sheet | |
var range = sheet.getDataRange(); // get range object containing data | |
var data = range.getValues(); // write range data into array called data | |
Logger.log(data); // Log Data. To see the result run function and press <Ctrl + Enter> | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getDataElementsFromSheet() | |
{ | |
var sheet = SpreadsheetApp.getActiveSheet(); // get active sheet | |
var range = sheet.getDataRange(); // get range object containing data | |
var data = range.getValues(); // write range data into array called data | |
getDataElements(data); // To see the result run function and press <Ctrl + Enter> | |
} | |
function getDataElements(data) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=ArrayFormula( | |
transpose(split(rept(concatenate(A2:A&char(9)),counta(B2:B)),char(9))) | |
&" "& | |
transpose(split(concatenate(rept(B2:B&char(9),counta(A2:A))),char(9))) | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function make2DDataValidation() { | |
// ............................... Settings ...................................... | |
// Sheet names | |
var tsheet = 'Sheet1'; // The name of the work sheet with data validation | |
var dsheet = 'data'; // The name of the data sheet | |
// The data validation range: | |
var rownum = 1000; // The number of the last row of validation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=ADDRESS(1,1,4,,"Sheet1")&":"&ADDRESS(COUNTA(Sheet1!A:A),COUNTA(Sheet1!1:1),4) |
OlderNewer