Create New Item
string siteUrl = "http://sp2013";
ctx ctx = new ctx(siteUrl);
List oList = ctx.Web.Lists.GetByTitle("MyList");
ListItemCreationInformation lstCre = new ListItemCreationInformation();
ListItem oListItem = oList.AddItem(lstCre);
oListItem["Title"] = "Hello World";
oListItem.Update();
ctx.ExecuteQuery();
Update List Item
string siteUrl = "http://sp2013";
ctx ctx = new ctx(siteUrl);
List oList = ctx.Web.Lists.GetByTitle("MyList");
ListItem oListItem = oList.GetItemById(5);
oListItem["Title"] = "Hello World Updated!!!";
oListItem.Update();
ctx.ExecuteQuery();
Delete List Item
string siteUrl = "http://sp2013";
ctx ctx = new ctx(siteUrl);
List oList = ctx.Web.Lists.GetByTitle("MyList");
ListItem oListItem = oList.GetItemById();
oListItem.DeleteObject();
ctx.ExecuteQuery();
string siteUrl = "http://sp2013";
ctx ctx = new ctx(siteUrl);
List oList = ctx.Web.Lists.GetByTitle("MyList");
ListItemCreationInformation lstCre = new ListItemCreationInformation();
ListItem oListItem = oList.AddItem(lstCre);
oListItem["Title"] = "Hello World";
oListItem.Update();
ctx.ExecuteQuery();
Update List Item
string siteUrl = "http://sp2013";
ctx ctx = new ctx(siteUrl);
List oList = ctx.Web.Lists.GetByTitle("MyList");
ListItem oListItem = oList.GetItemById(5);
oListItem["Title"] = "Hello World Updated!!!";
oListItem.Update();
ctx.ExecuteQuery();
Delete List Item
string siteUrl = "http://sp2013";
ctx ctx = new ctx(siteUrl);
List oList = ctx.Web.Lists.GetByTitle("MyList");
ListItem oListItem = oList.GetItemById();
oListItem.DeleteObject();
ctx.ExecuteQuery();