sameer shaikh

sameer shaikh

  • NA
  • 177
  • 39.2k

How to perform CRUD operation in WebApi By using IEnumerable

Jun 28 2016 12:47 AM
Hi 
 
I have created a Model class name is as Movie.cs in WebApi and its Properties are below
[Key]
public int Movie_Id { set; get; }
public string Movie_Name { set; get; }
public DateTime Reales_Date { set; get; }
public string Actress_Name { set; get; }
public string Actor_Name { set; get; }
public string Director_Name { set; get; }
 
and in controller created a list i.e List<Movie> list_movies=new List<Movie>();
and add some values in list.
 
now i want to perform GET,GET with Id,PUT,POST,DELETE operation on this list by using IEnumerable datatype..
 
so please help me how to write code of that Operation...
 
thanks for your help
Regards
Sameer 
 
 
 

Answers (4)