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
Attribute VB_Name = "Module1" | |
Option Explicit | |
#If VBA7 And Win64 Then | |
'64bit版 | |
Public Declare PtrSafe Function OpenClipboard Lib "user32" (ByVal hWnd As Long) As Long | |
Public Declare PtrSafe Function EmptyClipboard Lib "user32" () As Long | |
Public Declare PtrSafe Function CloseClipboard Lib "user32" () As Long | |
Public Declare PtrSafe Function SetClipboardData Lib "user32" (ByVal uFormat As Long, ByVal hData As Long) As Long | |
Public Declare PtrSafe Function GlobalAlloc Lib "kernel32" (ByVal uFlag As Long, ByVal dwBytes As Long) As Long |
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
// EEPROMから文字列を読み込む | |
#include <U8g2lib.h> | |
#include <U8x8lib.h> | |
#include <Wire.h> | |
#include <EEPROM.h> // EEPROM の読み出しのため | |
// SSD1306をディスプレイとして利用するためのコンストラクタ | |
U8G2_SSD1306_128X32_UNIVISION_F_SW_I2C u8g2( | |
U8G2_R0, /* clock= */ | |
SCL, /* 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
// EEPROMから文字列を読み込む、LCD に起動画面を表示 | |
#include <U8g2lib.h> | |
#include <U8x8lib.h> | |
#include <Wire.h> | |
#include <EEPROM.h> // EEPROM の読み出しのため | |
// SSD1306をディスプレイとして利用するためのコンストラクタ | |
U8G2_SSD1306_128X32_UNIVISION_F_SW_I2C u8g2( | |
U8G2_R0, /* clock= */ | |
SCL, /* 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
// EEPROMから文字列を読み込む、LCD に起動画面を表示 | |
// 使用開始のためのパスコードもEEPROMに保存 | |
// キーボードデバイスとして認識させて、文字列を送出! | |
#include <U8g2lib.h> | |
#include <U8x8lib.h> | |
#include <Wire.h> | |
#include <EEPROM.h> // EEPROM の読み出しのため | |
#include "Keyboard_jp.h" // HID(Keyboard)のため | |
// 参考: https://mgt.blog.ss-blog.jp/2016-01-14 |
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
// EEPROMから文字列を読み込む、LCD に起動画面を表示 | |
// 使用開始のためのパスコードもEEPROMに保存 | |
// キーボードデバイスとして認識させて、文字列を送出! | |
// #define EEP_INIT // EEPROM に初期値を設定する場合に有効化 | |
// #define DEBUG // デバッグ時に有効化、完成時には無効化 | |
#ifndef EEP_INIT | |
// EEPROM に初期値を書き込む場合には、LCDを使用しない | |
#include <U8g2lib.h> |
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
'use strict' | |
//---------------------------------------------------------------------------- | |
// チェック結果をクリア(列 A~F) | |
function checkClear( ) { | |
SpreadsheetApp.getActiveSheet().getRange( 'A:F' ).clearContent( ); | |
SpreadsheetApp.getActiveSheet().getRange( 'G1' ).clearContent( ); | |
} | |
/******************************************************************************** |
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
'use strict' | |
//---------------------------------------------------------------------------- | |
// スプレッドシートにメニュー項目を追加する | |
function onOpen( ) { | |
Logger.log( "[開始] メニュー項目を追加" ); | |
SpreadsheetApp.getUi( ) | |
.createMenu( 'クラスの移譲' ) | |
.addItem( '参加クラスの取得', 'getOwnerCourses' ) |
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
'use strict' | |
//---------------------------------------------------------------------------- | |
// チェック結果をクリア | |
function checkClear( ) { | |
checkClear0( ); | |
checkClear1( ); | |
} | |
//---------------------------------------------------------------------------- |
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
'use strict' | |
function getPageDate( ) { | |
// 現在開いているシートを取得する | |
const sheet = SpreadsheetApp.getActiveSheet( ); | |
let i = 3; | |
if ( sheet.getRange( 1, 5 ).getValue( ) != "" ) { | |
i = sheet.getRange( 1, 5 ).getValue( ); | |
} |
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
"use strict"; | |
// 半角英数字と一部記号からランダムな8桁文字列を生成する | |
// | |
// ※ https://javascript.programmer-reference.com/js-create-random-string/ | |
function getRndStr( len ) { | |
//使用文字の定義 | |
var str = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!#$%&"; | |
//ランダムな文字列の生成 |