PDA

View Full Version : Receiving Payload variables in event



bhopp@matrixcomputer.com
November 25th, 2006, 12:59 AM
I have an event 'TheaterTekLaunchAndPlay' as below:

local reg, err, val
local quote = '\"'
local cFile = 'C:\\LASTHOLIDAY_WS\\VIDEO_TS\\VIDEO_TS.IFO'
reg, err = win.CreateRegistry("HKLM", [[SOFTWARE\TheaterTek\AutoKiller]])
print("TheaterTekLaunchAndPlay")
if (reg == nil) then
print(err)
else
val, err = reg:Read("Path")
if (val == nil) then
print(err); return
else
print("Start Theatertek DVD, val:"..val)
reg:CloseKey()
win.ShellExecuteEx(val,cFile,"", SW_SHOWNORMAL) -- Launch TheaterTek DVD 2.0
end
end

This seems to work when I call it via Com / Ole. My question is how can I pass the movie filename (which currently resides in cFile) as a payload variable so I can launch any movie I wish from my remote application. My current undesireable way would require to setup an event for each and every movie I wish to run. It seems there are 4 payload variables available I just don't know how to receive them in the event script.

Thanks,

Byron...

bhopp@matrixcomputer.com
November 25th, 2006, 02:14 AM
O.K. I figured this out by simply using the variable name pld1 for my parameter. I will keep moving on...

Byron...