Skip to content

Instantly share code, notes, and snippets.

#SingleInstance,Force
Appskey & z:: ;launch my zoom meeting
run %comspec% /c ""%A_AppData%\Zoom\bin\Zoom.exe" "--url=zoommtg://zoom.us/join?action=join&confno=8155790366&pwd=myPassword"",,hide
WinWait, Zoom Meeting
Sleep, 100
Send !v ;Alt V is typical hotkey for toggling video
return
;*******************************************************
; Want a clear path for learning AutoHotkey; Take a look at our AutoHotkey Udemy courses. They're structured in a way to make learning AHK EASY
; Right now you can get a coupon code here: https://the-Automator.com/Learn
;*******************************************************
XL:=XL_Handle(1) ;Get pointer to Excel
;***********call function*******************
loc:=XL_Find_Headers_in_Cols(XL,["email","country","Age"]) ;pass search terms as an array
MsgBox % "email: " loc["email"] . "`nCountry: " loc["country"] . "`nAge: " loc["Age"]
;********************search***Find columns based on header********************************.
;~The script needs to be run at an elevated level- this takes care of that
if (! A_IsAdmin){ ;http://ahkscript.org/docs/Variables.htm#IsAdmin
Run *RunAs "%A_ScriptFullPath%" ; Requires v1.0.92.01+
ExitApp
}
;be sure to use 32-bit AutoHotkey
ParseJSON(jsonStr){
static SC:=ComObjCreate("ScriptControl"),C:=Chr(125)
SC.Language:="JScript",ComObjError(0),SC.ExecuteStatement("function arrangeForAhkTraversing(obj){if(obj instanceof Array){for(var i=0; i<obj.length; ++i)obj[i]=arrangeForAhkTraversing(obj[i]);return ['array',obj];" C "else if(obj instanceof Object){var keys=[],values=[];for(var key in obj){keys.push(key);values.push(arrangeForAhkTraversing(obj[key]));" C "return ['object',[keys,values]];" C "else return [typeof obj,obj];" C ";obj=" jsonStr)
return convertJScriptObjToAhks(SC.Eval("arrangeForAhkTraversing(obj)"))
}ConvertJScriptObjToAhks(JSObj){
if(JSObj[0]="Object"){
Obj:=[],Keys:=JSObj[1][0],Values:=JSObj[1][1]
while(A_Index<=Keys.length)
Obj[Keys[A_Index-1]]:=ConvertJScriptObjToAhks(Values[A_Index-1])
;*******************************************************
; Want a clear path for learning AutoHotkey; Take a look at our AutoHotkey Udemy courses. They're structured in a way to make learning AHK EASY
; Right now you can get a coupon code here: https://the-Automator.com/Learn
;************************************************************
IniRead, API_Token ,Auth.ini,API, Token
;~ Endpoint:="http://api.openweathermap.org/data/2.5/weather" ; Review https://duckduckgo.com/api for documentation
Endpoint:="http://api.openweathermap.org/data/2.5/forecast/daily" ; Review https://duckduckgo.com/api for documentation
;~ QueryString:=QueryString_Builder({"zip":"75019,us","APPID":API_Token})
;~ QueryString:=QueryString_Builder({"lat":"32.9915376","lon":"-96.9799073","APPID":API_Token})
d::
if (a_timesincepriorhotkey != -1 && a_timesincepriorhotkey<200)
cnt += 1
else if (a_timesincepriorhotkey > 400)
cnt := 0
if (cnt == 0)
var := "single click"
if (cnt == 1)
var := "double click"
Browser_Forward::Reload
Browser_Back::
var:="2"
;~ Ternary operator
;~ (condition)?(True) : (False)
data:= (var="3")?("is one"):("Not One")
MsgBox % data
data:= (Var="1")?("one")
:(Var="2")?("two")
;*******************************************************
; Want a clear path for learning AutoHotkey; Take a look at our AutoHotkey Udemy courses. They're structured in a way to make learning AHK EASY
; Right now you can get a coupon code here: https://the-Automator.com/Learn
;*******************************************************
#SingleInstance,Force
var=
(
Email First_Name Last_Name Phone
[email protected] Joy Senilg 123.456.7801
[email protected] Joe Glines 234.654.4321
#SingleInstance,Force
var=
(
Email First_Name Last_Name Phone
[email protected] Joy Senilg 123.456.7801
[email protected] Joe Glines 234.654.4321
[email protected] Jon Seling 567.890.6543
[email protected] Jon Seling 345.234.1322
)
obj:={} ;Need to declare object first
#SingleInstance,Force
Browser_Forward::Reload
Browser_Back::
XL_Handle(XL,1) ;get handle to Application
;***********freeze panes in Excel*******************
XL_Freeze(XL,Row:="") ;turns off freeze panes
XL_Freeze(XL,Row:="1",Col:="B") ;freeze first row and first column
XL_Freeze(XL,Row:="2",Col:="b") ;just freeze columns at b
XL_Freeze(XL,Row:="1",Col:="b") ;just feeze rows at 1