public string UpdateECategories(string companyCode, string json) { clsDataAccessor dataAccessor = new clsDataAccessor(); dataAccessor.connectionstring = dataAccessor.getConnectionString_Vapt(dataAccessor, companyCode); ECategories EC = new ECategories(); var serializer = new System.Web.Script.Serialization.JavaScriptSerializer(); string response = ""; /* json = @"{ * ""cat_id"":""12122222"", * ""cat_code"":""Testing181212"", * ""cat_descp"":""test"", * ""cat_otherlanguage"":"""", * ""cat_createdate"":""2019-11-07"", * }"; * * passing value : * {"eCategory":[{"cat_id":"1","cat_code":"Bird’s Nest & Snow Jelly","cat_descp":"Bird’s Nest & Snow Jelly","cat_otherlanguage":"","cat_createdate":"2019-11-13"}, * {"cat_id":"2","cat_code":"Dried Bird’s Nest","cat_descp":"Dried Bird’s Nest","cat_otherlanguage":"","cat_createdate":"2019-11-13"}]} */ try { EC = serializer.Deserialize <ECategories>(json); } catch (Exception ex) { return(ex.ToString()); } response = dataAccessor.updateECateoriesData(EC); return(response); }