This file contains hidden or 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
| // ==UserScript== | |
| // @name End of Module Return to Home | |
| // @namespace _| /\ |< { | |
| // @version 0.1 | |
| // @description Send user to home page when reaching end of module page instead of going to the next module | |
| // @author Jake Standish [email protected] | |
| // @match https://*.instructure.com/*/pages/* | |
| // @grant none | |
| // ==/UserScript== |
This file contains hidden or 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
| ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
| // CANVAS API Call Template | |
| // by Jake Standish [[email protected]] | |
| // Written December, 2016 | |
| // You are free to copy and moodify this code at your own risk. | |
| // | |
| // INSTRUCTIONS | |
| // 1. Copy this code. | |
| // 2. Open a google apps script file from a Google Spreadsheet, Form, Document, or Google Apps Script (script.google.com). | |
| // 3. Obtain your access token from Canvas and paste it's value in the parenthese after var accessToken = |
This file contains hidden or 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 deleteExtraColsAndRows() { | |
| var ss = SpreadsheetApp.getActiveSheet() | |
| //Columns | |
| var lastCol = ss.getLastColumn(); | |
| var endc = ss.getMaxColumns(); | |
| try{ | |
| ss.deleteColumns(lastCol+1, endc-lastCol); | |
| }catch(e){Logger.log('col error: '+e)} | |
This file contains hidden or 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
| ////////////////////////////////////////////////////////////////////////// | |
| // Install within a Google Form and have the "On Form Submit" trigger set | |
| // canvasAPI function is seperate and can be found by searching the Canvas Community for [email protected] | |
| ////////////////////////////////////////////////////////////////////////// | |
| function onFormSubmit(e) { | |
| var email = e.response.getRespondentEmail(); | |
| var random = Math.floor(Math.random() * 9999); | |
| var ssID = ""; //put destination spreadsheetID here | |
| var ss = SpreadsheetApp.openById(ssID); |
This file contains hidden or 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
| /////////////////////////////////////////////////////// | |
| // Google Form Email Script | |
| // Author: Jacob Standish ([email protected]) | |
| // This script sends an email to a person or group every time the form is submitted | |
| // The body of the message contains the responses from the form styled with the form questions as HEADING2 and responses as Paragraphs. | |
| // This script needs to be installed into a Google Form (not the spreadsheet) with the On Form Submit trigger set | |
| /////////////////////////////////////////////////////// | |
| var recipients = "[email protected]"; //replace with the address you want to receive the email |
This file contains hidden or 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
| //////////////////////////////////////////////////////////////////////// | |
| //The function takes two inputs: | |
| //url = Spreadhsheet URL | |
| //sheetName = name of sheet in Spreadsheet you want to convert to json | |
| //The resulting json objects will be a named based on text in the cells of row 1 with spaces removed | |
| //////////////////////////////////////////////////////////////////////// | |
| function getSpreadsheetData(ssURL,sheetName){ | |
| var ss = SpreadsheetApp.openByUrl(ssURL); | |
| var sheet = ss.getSheetByName(sheetName); | |
| var data = sheet.getDataRange().getValues(); |