How to add Arguments to a CefProcessMessage?

Having problems with building or using the CefGlue .NET/Mono binding? Ask your questions here.

Moderator: fddima

How to add Arguments to a CefProcessMessage?

Postby tjhighpoint » Thu May 30, 2013 3:42 pm

I see how to create a CefProcessMessage, like this:

var message = CefProcessMessage.Create("myMsg");

and I see there is a getter for message.Arguments.

But how do I create/add arguments to Arguments before calling CefBrowser.SendProcessMessage ? It's a read-only get property.
tjhighpoint
Newbie
 
Posts: 2
Joined: Tue May 07, 2013 1:38 pm

Re: How to add Arguments to a CefProcessMessage?

Postby fddima » Fri May 31, 2013 3:46 am

Hi. It can be done like in sample: https://bitbucket.org/xilium/xilium.cef ... ult#cl-151
Code: Select all
var message = CefProcessMessage.Create("myMessage1");
var arguments = message.Arguments;
arguments.SetString(0, "hello");
arguments.SetInt(1, 12345);
arguments.SetDouble(2, 12345.6789);
arguments.SetBool(3, true);

browser.SendProcessMessage(CefProcessId.Renderer, message);
fddima
Master
 
Posts: 788
Joined: Tue Dec 07, 2010 6:10 am


Return to CefGlue Forum

Who is online

Users browsing this forum: No registered users and 9 guests