开发者

ASP.Net Dynamic Data with Xml or Alternative

I have to display data in a web application with the ability to filter. The data is ported via FTP as XML. Can I use Dynamic Data to handle this or is there an alternative way. I do know I can manually linq to the xml and display in datagrid or some other control but the Dynamic Data Template seems to offer开发者_开发百科 all the Data management functionality.


ya use JSON and JQUERY here is code from which i filter account no,

$(function () {
     var search = $("#<%=txtAccountNo.ClientID%>");
     search.watermark('Enter Account No');
     search.autocomplete({
         source: function (request, response) {
             $.ajax({
                 url: '<%=ResolveUrl("~/") %>AutoCompleteService.asmx/GetAccountNo',
                 data: "{ 'prefixText': '" + search.val() + "', 'count' : '10','contextKey':''}",
                 dataType: "json",
                 type: "POST",
                 contentType: "application/json; charset=utf-8",
                 dataFilter: function (data) { return data; },
                 success: function (data) {
                     if (data.d != null) {
                         response($.map(data.d, function (item) {
                             return {
                                 value: item
                             }
                         }))
                     }
                 },
                 error: function (XMLHttpRequest, textStatus, error) {
                     //alert(textStatus);
                 }
             });
         },
         minLength: 1
     });
 });
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜