Created
April 1, 2016 01:51
-
-
Save itoshige/f7c9fc97cc38b96d0c6f2449dca6d443 to your computer and use it in GitHub Desktop.
幹事決定スロット
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
<html> | |
<head> | |
<title>幹事決定スロット</title> | |
<HTA:APPLICATION | |
ID="thisHTA" | |
SCROLL="no" | |
MAXIMIZEBUTTON="no" | |
MINIMIZEBUTTON="no" | |
SINGLEINSTANCE="yes" | |
SCROLLFLAT="yes" | |
SHOWINTASKBAR="no" | |
/> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta http-equiv="content-type" content="text/html; charset=utf-8" /> | |
<script type="text/javascript"> | |
window.resizeTo(300,200); | |
var FORREADING = 1; // 読み取り専用 | |
var TRISTATE_TRUE = -1; // Unicode | |
var TRISTATE_FALSE = 0; // ASCII | |
var TRISTATE_USEDEFAULT = -2; // システムデフォルト | |
var fs = new ActiveXObject( "Scripting.FileSystemObject" ); | |
var file = fs.OpenTextFile( 'member.txt', FORREADING, true, TRISTATE_FALSE ); | |
var members = []; | |
while( !file.AtEndOfStream ) { | |
var member = file.ReadLine(); | |
if(member.indexOf('#') !== -1) { | |
} else { | |
members.push( member ); | |
} | |
} | |
file.Close(); | |
fs = null; | |
tID = 0; | |
function startSlot(){ | |
x=Math.floor(Math.random(1)*(members.length)) | |
document.getElementById('organizer').innerHTML = members[x] + ' さん'; | |
tID=setTimeout("startSlot()",100); | |
} | |
function stopSlot() { | |
clearTimeout(tID); | |
} | |
//--> | |
</script> | |
</head> | |
<body> | |
<h3 id='organizer'>startボタンを押してください</h2> | |
<form> | |
<input type="button" value="start" onClick="clearTimeout(tID);startSlot()"> | |
<input type="button" value="stop" onClick="stopSlot();"> | |
</form> | |
</body> | |
</html> |
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
#AAA | |
BBB | |
#CCC | |
あああ | |
いいい | |
ううう | |
えええ | |
#おお |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment