Nov 18, 2013, 8:58 AM
POST Request with ComponentLoader not work
Hello,
I need to do a Component Loader request using the POST method.
I'm in Desktop scenario and into the main ASPX (where there is a Desktop object)
I have a DirectMethod that open dynamically window into the Desktop.
What is the problem?
Thanks in advance.
I need to do a Component Loader request using the POST method.
I'm in Desktop scenario and into the main ASPX (where there is a Desktop object)
I have a DirectMethod that open dynamically window into the Desktop.
var createWindow = function (pageName, params) {
App.direct.createWindow(page, params);
};
[DirectMethod(ShowMask = true)]
public void createWindow(string pageName, string info)
{
Info i = JsonConvert.DeserializeObject<Info>(info);
Window wnd = new Window
{
ID = pageName,
CloseAction = CloseAction.Destroy,
Layout = "FitLayout",
Title = "Title",
Loader = new ComponentLoader
{
Url = "/Pages/"+pageName+".aspx",
Mode = LoadMode.Frame,
LoadMask =
{
ShowMask = true,
Msg = "Loading..."
}
,AjaxOptions = new AjaxOptions{
FormID = "ao_" + pageName,
Method = HttpMethod.POST,
}
}
};
wnd.Loader.Params.Add(new Parameter("info", JsonConvert.SerializeObject(i)));
Desktop1.CreateWindow(wnd);
}
The request work but the "info" parameter is always send in GET.What is the problem?
Thanks in advance.