Skip to content

Instantly share code, notes, and snippets.

@tdalon
tdalon / Teams_BackgroundImport.ahk
Created October 20, 2023 14:41
Import Teams meeting background files in Teams New
Teams_BackgroundImport(srcDir:=""){
; https://techcommunity.microsoft.com/t5/microsoft-teams-public-preview/backgrounds/m-p/3782690
If GetKeyState("Ctrl") {
Teamsy_Help("bgi")
return
}
If !Teams_IsNew()
{
return
@tdalon
tdalon / EmailShareActiveUrl.ahk
Created October 16, 2023 07:15
Quick Share Url by Email with AutoHotkey
; IntelliSharebyEmailActiveURL Ctrl+Shift+M
#If Browser_WinActive()
^+m:: ; <--- [Browser] Share by eMail active url
EmailShareActiveUrl:
If GetKeyState("Ctrl") and !GetKeyState("Shift") {
Run, "https://tdalon.blogspot.com/2023/10/share-url-by-email.html"
return
}
sLink := Browser_GetUrl()
@tdalon
tdalon / Teams_GetMainWindow.ahk
Last active October 13, 2023 12:18
AutoHotkey Script to Get Main Microsoft Teams Window
Teams_GetMainWindow(){
; See implementation explanations here: https://tdalon.blogspot.com/get-teams-window-ahk
; Syntax: hWnd := Teams_GetMainWindow()
WinGet, WinCount, Count, ahk_exe Teams.exe
If (WinCount = 0)
GoTo, StartTeams
If (WinCount = 1) {
@tdalon
tdalon / Jira_EditEpic.ahk
Last active July 28, 2023 14:40
Jira Quick Set Epic with AutoHotkey
Jira_EditEpic(IssueKey, EpicKey:="", EpicLinkCfId:="") {
; suc := Jira_EditEpic( IssueKey, EpicKey, EpicLinkCfId:="")
JiraRootUrl := Jira_IssueKey2RootUrl(IssueKey)
If (EpicLinkCfId ="") {
EpicLinkCfId := Jira_GetCfId(JiraRootUrl,"Epic Link")
}
If (EpicKey ="") {
EpicKey := Jira_IssueKey2EpicKey(IssueKey,"",JiraRootUrl)
}
@tdalon
tdalon / DatePicker.ahk
Last active July 20, 2023 01:17
Universal Date Picker for Windows implemented with AutoHotkey
; Ctrl+,
^,:: ; CurrentDate
FormatTime, CurrentDateTime,, yyyy-MM-dd
SendInput %CurrentDateTime%
return
; Ctrl+.
^.:: ; DatePicker
DatePicker(sDate)
@tdalon
tdalon / ListView_Select.ahk
Last active July 18, 2023 13:29
Dynamic ListView with Search box to filter supporting wildcard syntax
; ListView with Search by wildcard
; Selection := ListView_Select(LVArray,Title:="",Name)
; LVArray: can be multidimensional array, each row matching a ListView row
; Name : Column Names separated by |
ListView_Select(LVArray,Title:="", Name := "Name")
{
static LVSSearchValue
static LVSListView
Gui, ListView_Select:New,,%Title%
@tdalon
tdalon / GetCellNamedValue.pq
Last active July 17, 2023 17:06
Excel PowerQuery: Get Cell Named Value
(CellName as text) =>
let
Source = Excel.CurrentWorkbook(){[Name=CellName]}[Content],
Value = Source{0}[Column1]
in
Value
@tdalon
tdalon / Confluence_PersonalizeMention.ahk
Created July 6, 2023 14:39
AutoHotkey: Confluence: Personalize mention
Confluence_PersonalizeMention() {
If GetKeyState("Ctrl") {
Run, "https://tdalon.blogspot.com/2023/07/confluence-personalize-mentions.html"
return
}
ClipboardBackup := Clipboard
SendInput {Ctrl down}{Shift down}{Left}
SendInput {Ctrl up}{Shift up}
sClip := Clip_GetSelection(False)
@tdalon
tdalon / Jira.ahk
Last active June 22, 2023 06:38
Extract of AutoHotkey Library for Jira REST API
; ----------------------------------------------------------------------
Jira_Get(sUrl,sPassword:=""){
; Syntax: sResponseText := Jira_Get(sUrl,sPassword*)
; sPassword Password for server or Api Token for cloud
; Calls: Jira_BasicAuth
If !RegExMatch(sUrl,"^http") ; missing root url or default url
sUrl := Jira_GetRootUrl() . sUrl
sAuth := Jira_BasicAuth(sUrl,sPassword)
@tdalon
tdalon / Jira.bas
Created June 20, 2023 14:29
Jira Excel VBA Basic functions
' Password can be stored in %userprofile%/JiraPassword.txt (see GetPassword function) to avoid being prompted each time
Private pJiraClient As WebClient
Private pJiraPassword As String
Private pJiraRootUrl As String
Private pJiraUserName As String
Private Property Get JiraPassword() As String