I have now with help of Mikeyww got this in action. But there are several cliboard contents which do not yet exist as a key or value in object. And I do want to create them manually in the list later.
Code: Select all
F12::
Clipboard := "A kiwi" ;Or any other fruit that is not yet in the list, so it could be anything, no way to know all beforehand.
email := {"A banana": "[email protected]", "An apple": "[email protected]"}
MsgBox % email[Clipboard]
;SendInput % email[Clipboard]
return
Code: Select all
F12::
email := {"A banana": "[email protected]", "An apple": "[email protected]"}
If (email ~= Clipboard)
MsgBox, % email[Clipboard]
else
MsgBox, % Clipboard
return