-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCreateAutoHotkeyEngine.cs
More file actions
38 lines (31 loc) · 991 Bytes
/
CreateAutoHotkeyEngine.cs
File metadata and controls
38 lines (31 loc) · 991 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
using System;
using Robin.Core;
using Robin.Core.Attributes;
namespace Modules.AhkTest8
{
[Action(Order = 4)]
[Throws("ActionError")] // TODO: change error name (or delete if not needed)
public class CreateAutoHotkeyEngine : ActionBase
{
#region Properties
[OutputArgument]
public AutoHotkey.Interop.AutoHotkeyEngine AhkEngine { get; set; }
#endregion
#region Methods Overrides
public override void Execute(ActionContext context)
{
try
{
var ahk = new AutoHotkey.Interop.AutoHotkeyEngine();
AhkEngine = ahk;
}
catch (Exception e)
{
throw new ActionException("ActionError", e.Message, e.InnerException); // TODO: change error name (or delete if not needed)
}
// TODO: set values to Output Arguments here
// OutputArgument1 = ...
}
#endregion
}
}