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
gen( len ) | |
{ | |
loop % (122, d="~") | |
cStr .= chr( (i:=a_index)>32&&i<60 ? i : i>59&&i<91 ? i : i>93&&i<125 ? i : "" ) d | |
cStr:=regexreplace(cStr, d d) | |
while ( strlen(nStr)<len ) | |
{ | |
sort, cStr, % "Random D" d | |
nStr .= ((v:=substr(regexreplace(cStr,d),1,20))~="\d" |
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
ExecScript( Script, Params="", AhkPath="" ) | |
{ | |
AhkPath := !AhkPath ? A_AhkPath : AhkPath | |
Loop % ( 2, Pipe := [], Name := "AHK_" A_TickCount ) | |
Pipe[A_Index] := DllCall( "CreateNamedPipe", "Str", "\\.\pipe\" name, "UInt", 2, "UInt", 0 | |
, "UInt", 255, "UInt", 0, "UInt", 0, "UPtr", 0, "UPtr", 0, "UPtr" ) | |
if !FileExist( AhkPath ) | |
throw Exception( "AutoHotkey runtime not found: " AhkPath ) |
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
// Waveファイル 読み込みと書き込み | |
// 16bit形式のみ対応 | |
// 読み込んだデータはList<short>に格納されます | |
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
namespace ConsoleApplication1 | |
{ | |
class Program |
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
msgbox % EnumClipFormats() | |
EnumClipFormats() | |
{ | |
DllCall("OpenClipboard"), VarSetCapacity( buf, 256 ) | |
Loop % DllCall("CountClipboardFormats") | |
{ | |
fmt := DllCall("EnumClipboardFormats", uint, a_index=1?0:fmt ) | |
DllCall("GetClipboardFormatName", uInt, fmt, str, buf, int, 128 ) |
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
xlObj := ComExcelConnect( "ahk_class XLMAIN" ).Application | |
msgbox % xlObj.Range("A1").value | |
ExitApp | |
ComExcelConnect( WinTitle ) | |
{ | |
objID := "-16", objID &= 0xFFFFFFFF | |
refID := -VarSetCapacity( iid, 16 ) | |
iid_type := NumPut( 0x46000000000000C0 |
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() | |
{ | |
var view = | |
{ | |
init: function() | |
{ | |
this.cacheDom(); | |
this.render(); | |
}, | |
cacheDom: function() |
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
#SingleInstance, Off | |
#NoEnv | |
SetBatchLines, -1 | |
FilePath = C:\Windows\ShellNew\Template.ahk | |
DefaultName = %A_UserName% | |
DefaultDesc = | |
Indent := "`t" | |
Title = CodeQuickTester |
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
cSharp = | |
( | |
using System; | |
using System.Text; | |
using System.Runtime.InteropServices; | |
public class Win32ResourceReader : IDisposable | |
{ | |
private IntPtr _hModule; |
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
uri := "file:///D:/03%20Schreiben/01_Texte/15%20%E2%80%93%20Encyclop%C3%A4dien/Encyclopedia%20of%20Sociology.pdf" | |
msgbox % decodeURI( uri ) | |
decodeURI( u ) | |
{ | |
( obj:=ComObjCreate("HTMLfile") ).write("<p>/</p><script>document.getElementsByTagName(""p"")[0].innerHTML=decodeURI(`""" u `""");</script>") | |
return obj.getElementsByTagName("p")[0].innerHTML | |
} |
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
uri := "file:///D:/03%20Schreiben/01_Texte/15%20%E2%80%93%20Encyclop%C3%A4dien/Encyclopedia%20of%20Sociology.pdf" | |
msgbox % UriDecode( uri ) | |
UriDecode( u ) | |
{ | |
( obj := ComObjCreate( "ScriptControl" ) ).Language := "JScript" | |
return obj.Eval( "decodeURI(`""" u `""");" ) | |
} |