Guest User

Untitled

a guest
Dec 13th, 2017
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.10 KB | None | 0 0
  1. enter code here
  2.  
  3. using System;
  4. using System.Collections.Generic;
  5. using System.Linq;
  6. using System.Net;
  7. using System.Net.Http;
  8. using System.Web.Http;
  9. using System.Web.Mvc;
  10. using ProcessQ.Models;
  11. using System.Web.Script.Serialization;
  12.  
  13. namespace ProcessQ.Controllers
  14. {
  15. public class ValuesController : ApiController
  16. {
  17. // GET api/values
  18. public IEnumerable<string> Get()
  19. {
  20. string Json = System.IO.File.ReadAllText(@"C:UsersAlexDesktopOutput.json");
  21. JavaScriptSerializer ser = new JavaScriptSerializer();
  22. var personlist = ser.Deserialize<List<ItemsInsideProcessQ>>(Json);
  23. return View(personlist);
  24. }
  25.  
  26. // GET api/values/5
  27. public string Get(int id)
  28. {
  29. return "value";
  30. }
  31.  
  32. // POST api/values
  33. public void Post([FromBody]string value)
  34. {
  35. }
  36.  
  37. // PUT api/values/5
  38. public void Put(int id, [FromBody]string value)
  39. {
  40. }
  41.  
  42. // DELETE api/values/5
  43. public void Delete(int id)
  44. {
  45. }
  46. }
  47. }
Add Comment
Please, Sign In to add comment