Based on this : http://www.trirand.com/blog/?page_id=393/help/stypeselect-searchoptions-dataurl
I want to get data for dataUrl using a Web Method like this:
[WebMethod]
[ScriptMethod(ResponseFormat = ResponseFormat.Json)]
public static string SuppliersSelect()
{
using (NORTHWNDEntities context = new NORTHWNDEntities())
{
var list = context.Suppliers.ToList();
string select = “<select>”;
foreach (var item in list)
{
select += string.Format(“<option value='{0}’>{1}</option>”,item.SupplierID,item.CompanyName);
}
select += “</select>”;
return select;
}
}
The problem is I don’t know how to configure dataUrl to get data from this Web Method. I think dataUrl use GET method to get data and Web Methods use POST method.
How I can do this?
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top