Skip to content

Instantly share code, notes, and snippets.

;~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
}
alternative medicine
animation
apparel & fashion
architecture & planning
arts and crafts
automotive
aviation & aerospace
banking
biotechnology
broadcast media
;***********************Read and Write appointments from Calendar**************************.
;http://www.autohotkey.com/forum/viewtopic.php?t=61509&p=379775#379775
olFolderCalendar := 9 ; Outlook.OlDefaultFolders.olFolderContacts
olFolderContacts := 10 ; get constants from visual studio
olAppointmentItem = 1
profileName := "Outlook"
Outlook := ComObjCreate("Outlook.Application")
namespace := Outlook.GetNamespace("MAPI")
namespace.Logon(profileName)
#Include <default_Settings> ;RAlt::
global Obj:=[] ;Creates obj holder for variables
;~ https://autohotkey.com/board/topic/117747-calculating-difference-between-gmt-and-local-time/
;~ FormatTime, UTC, % A_NowUTC, yyyyMMddT HH:mm
Gui, Add, MonthCal, vMyCalendar
gui,Show
MsgBox % A_NowUTC
FormatTime, UTC, % A_NowUTC, yyyyMMddTHHmmssZ
MsgBox, %UTC% `n20180714T170000Z
RBTitle := 1
switch (RBTitle)
{
case 1:
msg := "Troubleshoot "
case 2:
msg := "Configure "
case 3:
msg := "Discuss "
@JoeGlines
JoeGlines / GUI example.ahk
Created April 1, 2022 16:45
Saving and Importing to a GUI - example from friday support call
#SingleInstance, Force
; Create the sub-menus for the menu bar:
Menu, FileMenu, Add, &New, Clear
Menu, FileMenu, Add
Menu, FileMenu, Add, &Import, Import
Menu, FileMenu, Add, &Export, Export
Menu, FileMenu, Add
Menu, FileMenu, Add, E&xit, GuiClose
a=1
b=2
c=a + b
*///////////////.
DEFINE !Describer (Buy2 !TOKENS (1) / Title !Tokens (1) / ord !Tokens (1) /Varys !CMDEND)
Desc !Varys /sort (!ORD) /stats Mean.
script "B:\SPSS\Scripts\S1\Swap Mean.SBS".
Script "B:\SPSS\Scripts\Change N to Count.SBS".
Script "B:\SPSS\Scripts\Parse\Move Row.sbs"("Other").
Script "B:\SPSS\Scripts\Parse\Move Row.sbs"("None of the above").
script 'B:\SPSS\Scripts\Parse\Change Title.sbs' (!Title).
Script "B:\SPSS\Scripts\S1\Size labels to avoid line-wrapping.sbs".
!ENDDEFINE.
GitName:="JoeGlines" ;Add your name here
if (!GitName){
MsgBox You need to provide the name of your GIT...
Exitapp
}
;***********just sort*******************
SQL_UpperCase_Sort:
Clipboard_Backup_Copy_Selected_Text()
Sort, Clipboard, U CL ;sort, case insensitive, remove duplicates
gosub Remove_Blank_Lines
Clipboard := RegExReplace(Clipboard,"m)^[_\s]*|[_\s]*$") ;removes spaces at beginning and end
Source:="Sort, Uppercase, Dedupe and count"
gosub Count_Rows
Clipboard_Paste_and_Restore_Clipboard(Clipboard_Backup)