Esempio n. 1
0
        public void ConsultarPaquete()
        {
            Paquete paquete          = new Paquete();
            JavaScriptSerializer jss = new JavaScriptSerializer();

            Context.Response.Clear();
            Context.Response.ContentType = "application/json";
            string json  = "";
            var    lista = paquete.Consultar();

            json = jss.Serialize(lista);
            json = Regex.Replace(json, @"\""\\/Date\((-?\d+)\)\\/\""", "$1");
            json.Replace(@"\", string.Empty);
            Context.Response.Write(json);
        }