Page 1 of 1

Issuing MLServerCmd for specific client

Posted: Sat Jan 24, 2009 6:16 pm
by itanic
I was hoping to use PhotoLobby for a screensaver and was wondering how you specify the specifc client you want to issue MLServer commands to. They all seem generic without client options.

Posted: Sat Jan 24, 2009 11:40 pm
by CinemarDave
You will have to wrap the MLPhotoLobby commands in a MLScript and use the MLServer.CmdReceiveClient <<command>>,<<client>> command to send the command as the client.

Posted: Sun Jan 25, 2009 10:54 am
by itanic
Dave,

Thanks for the help. I don't see this command "MLServerCmdReceiveClient" in the wiki - must be undocumented. Anyway, I'm have problems getting started. I've tried the following MLScript figuring its the first step in the process but I get no response (Params(0) is "DenPC") or error message in the log.

Sub StartScreenSaver(Params)

MLServer.CmdReceiveClient "MLServeCmd.MLPhotoLobby|SetFolder~3,"&Params(0)

End Sub

After I get this working, I figure to set the variable "Photos_selecteditem_{{clientname}} to "1" and then run the Select.Photoitem command map. Do you see any problems with this approach?

Posted: Sun Jan 25, 2009 8:24 pm
by CinemarDave

Code: Select all

Option Explicit

Sub StartScreenSaver(Params)
   MLServer.CmdReceiveClient "MLPhotoLobby|SetFolder~3", Params(0)
End Sub


Assuming the MLScript was named "ScreenSaver" then the complete MLScript syntax would be

MLScript|ScreenSaver~StartScreenSaver~{{clientname}}