hello sir, I want to know why I can not retrieve data even if there are data inside it .
first error:
'Newtonsoft.Json.Linq.JArray' does not contain a definition for 'id'
"BedTypes":{"size":"2","BedType":[{"id":"14","description":"1 king bed"},{"id":"25","description":"2 twin beds"}]}
this is part of json where data is available.
foreach (var a in root.HotelRoomAvailabilityResponse.HotelRoomResponse)
{
try
{
string bedtypeid = a.BedTypes.BedType.id;
public class BedType
{
public string id { get; set; }
public string description { get; set; }
}
public class BedTypes
{
public string size { get; set; }
public BedType BedType { get; set; }
}