As I said .. I'm new to this and have no idea what you are saying here.
I mean .. yeah I understand what I need to do but ... have no idea how to do it. The only file I have that has anything to do with this item is Custom.xml which looks like this:
Code: Select all
<?xml version="1.0" encoding="UTF-8" ?>
<EventGhost Version="1710" Guid="{A2FA8D3F-40C5-4529-AEC2-BB8869A0FD8A}" Time="1470852097.65">
<Autostart Name="Autostart" Expanded="True">
<Plugin Identifier="Task" Guid="{D1748551-C605-4423-B392-FB77E6842437}" File="Task">
gAIpLg==
</Plugin>
<Action>
EventGhost.EnableExclusive(XmlIdLink(-1))
</Action>
<Plugin Identifier="Process" Guid="{82BADF9F-D809-4EBC-A540-CCBF7563F8DF}" File="ProcessWatcher">
gAIpLg==
</Plugin>
</Autostart>
<Macro Name="Start Program: ccRescan.exe" Expanded="True">
<Event Name="System.DeviceAttached" />
<Action>
System.Execute(u'C:\\Program Files (x86)\\CallClerk\\ccRescan.exe', u'', 3, False, 2, u'C:\\Program Files (x86)\\CallClerk', False, False, u'', False, False, False, False)
</Action>
</Macro>
</EventGhost>
I copied and pasted the Start Program: ccRescan.exe which looks like this:
Code: Select all
eg.plugins.System.Execute(u'C:\\Program Files (x86)\\CallClerk\\ccRescan.exe', u'', 3, True, 2, u'C:\\Program Files (x86)\\CallClerk', False, False, u'', False, False, False, False)
Now I'm lost ...
I created a script by going into "add macro" then selecting Python Script which looks like this:
Code: Select all
DEVICE = '\\\\?\\HID#VID_0BEF&PID_0004&MI_05#7&3a826eb7&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}'
if eg.event.payload[0] == DEVICE:
eg.plugins.System.Execute(u'C:\\Program Files (x86)\\CallClerk\\ccRescan.exe', u'', 3, True, 2, u'C:\\Program Files (x86)\\CallClerk', False, False, u'', False, False, False, False)
now the Custom.xml looks like this:
Code: Select all
<?xml version="1.0" encoding="UTF-8" ?>
<EventGhost Version="1710" Guid="{F3111992-B9EF-49E6-89BA-19D1511936DF}" Time="1470930128.07">
<Autostart Name="Autostart" Expanded="True">
<Plugin Identifier="Task" Guid="{D1748551-C605-4423-B392-FB77E6842437}" File="Task">
gAIpLg==
</Plugin>
<Action>
EventGhost.EnableExclusive(XmlIdLink(-1))
</Action>
<Plugin Identifier="Process" Guid="{82BADF9F-D809-4EBC-A540-CCBF7563F8DF}" File="ProcessWatcher">
gAIpLg==
</Plugin>
</Autostart>
<Macro Name="Start Program: ccRescan.exe" Expanded="True">
<Action>
EventGhost.PythonScript(u"DEVICE = '\\\\\\\\?\\\\HID#VID_0BEF&PID_0004&MI_05#7&3a826eb7&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}'\n\nif eg.event.payload[0] == DEVICE:\n eg.plugins.System.Execute(u'C:\\\\Program Files (x86)\\\\CallClerk\\\\ccRescan.exe', u'', 3, True, 2, u'C:\\\\Program Files (x86)\\\\CallClerk', False, False, u'', False, False, False, False)")
</Action>
<Action>
System.Execute(u'C:\\Program Files (x86)\\CallClerk\\ccRescan.exe', u'', 3, True, 2, u'C:\\Program Files (x86)\\CallClerk', False, False, u'', False, False, False, False)
</Action>
</Macro>
</EventGhost>
With this set up this way ... ccRescan now runs 3 times instead of 2
If I try to remove the System.DeviceAttached from tree so there is only Python Script and Start Program: ccRescan.exe it doesn't run at all.
I tried it as a Macro and as an Action
Same thing .. if I leave System.DeviceAttached in the tree .. it runs 3 times. If I disable System.DeviceAttached it doesn't run at all.
I know I'm doing something wrong but as I said .. I'm completely new to this program so I guess I don't know where to put the things you are telling me I need to do.
**just a note here ... the code pasted here is not what I pasted .. have no idea why it "word wraps" so the code here isn't showing exactly like what is in my file. Some of the lines are wrapped showing extra lines even tho they are on one line