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
#!/usr/bin/python | |
# input_text = editor.getSelText() | |
input_text = '=HLOOKUP(TablePeriods[[#Headers],[YearMonth]],TablePeriods[[#All],[YearMonth]],MATCH([@Date],INDIRECT("TablePeriods[[#All],["&[@Account]&"]]"),-1))' | |
# initialize the state table | |
state_table = {} | |
# event list and corresponding state table | |
event_list = ( "\"", "&", "(", ")", ",", "\n\r\t ", "[", "]", "{", "}" ) # last event is anything that doesn't match one of the other actions |
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
input_text = editor.getSelText() | |
EVENTS = 3 | |
STATES = 2 | |
state_table = [[[0,0] for x in range(EVENTS)] for x in range(STATES)] | |
event_list = [ "\"", "\n\r\t " ] # last event is anything that doesn't match one of the other actions | |
state_table[0] = [[1,0], [0,1], [0,0]] # normal state | |
state_table[1] = [[0,0], [1,0], [1,0]] # double-quote comment |
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
; Copied from http://www.autohotkey.com/board/topic/10412-paste-plain-text-and-copycut/ | |
#v:: ; Text–only paste from ClipBoard | WIN and V keys are the hotkey | |
KeyWait, LWin ; Wait for the Windows key to be lifted, | |
KeyWait, RWin ; since it would sometimes combine with the pasted text. | |
OldClip = %ClipBoardAll% ; Save formatted text for later | |
ClipBoard = %ClipBoard% ; Convert to text | |
Send ^v ; For best compatibility: SendPlay | simulates pressing CRTL and V keys | |
Sleep 50 ; Don't change clipboard while it is pasted! (Sleep > 0) | |
ClipBoard = %OldClip% ; Restore original ClipBoard | |
VarSetCapacity(OldClip, 0) ; Free memory |
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
#b:: ; Simulate typing of the text on the clipboard | |
KeyWait, LWin ; Ensure that the Windows key has been lifted. | |
KeyWait, RWin | |
ToPaste = %ClipBoard% ; Convert to text | |
Sleep 100 | |
StringReplace, ToPaste, ToPaste, `r`n, `n, All ; Prevent CR+LF from causing two newlines | |
Sleep 100 | |
SendRaw %ToPaste% ; SendRaw simulates typing the characters exactly, including AHK's special !^#+ characters | |
Return |
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
/:~ ~. 1!:1 <'C:/Path/ICD10/icd10withHierarchy.txt' | |
%&'()+,-./0123456789<=>ABCDEFGHIJKLMNOPQRSTUVWXYZ[]abcdefghijklmnopqrstuvwxyz |
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
InputBox, password, Enter Password for Archives, The generated archives will be protected with the password you enter below. Your input will be masked., hide | |
; Using FileSelectFolder is just one way of choosing your folders. | |
FileSelectFolder, sourcepath,,, Source Folder | |
sourcepath := RegExReplace(sourcepath, "\\$") ; Removes the trailing backslash, if present. | |
FileSelectFolder, destinationpath,,, Destination Folder | |
destinationpath := RegExReplace(destinationpath, "\\$") ; Removes the trailing backslash, if present. | |
sourcelen := StrLen(sourcepath) + 1 ; Determine the start of the variable part of the path. | |
Loop, Files, %sourcepath%\*.*, R | |
{ |
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
; Copied from http://www.autohotkey.com/board/topic/39551-change-the-default-mailto-to-gmail/ | |
; #NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. | |
; SendMode Input ; Recommended for new scripts due to its superior speed and reliability. | |
; SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory. | |
Haystack = %1% | |
;~ If no paramter is given when the run of it, it registers itself as the default mailto | |
; commented out because I'd rather set it as default by myself. |
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
<NotepadPlus> | |
<UserLang name="J" ext="ijs" udlVersion="2.1"> | |
<Settings> | |
<Global caseIgnored="yes" allowFoldOfComments="no" foldCompact="no" forcePureLC="0" decimalSeparator="0" /> | |
<Prefix Keywords1="no" Keywords2="no" Keywords3="no" Keywords4="no" Keywords5="no" Keywords6="no" Keywords7="no" Keywords8="no" /> | |
</Settings> | |
<KeywordLists> | |
<Keywords name="Comments">00NB. 01 02 03 04</Keywords> | |
<Keywords name="Numbers, prefix1"></Keywords> | |
<Keywords name="Numbers, prefix2"></Keywords> |
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
Option Explicit | |
Sub FindAllInstances() | |
Dim MyAR() As String | |
Dim i As Long | |
Dim match As String | |
match = "has" | |
i = 0 |
OlderNewer