Problem with converting int to string in Linq to entities

var items = from c in contacts select new ListItem { Value = c.ContactId, //Cannot implicitly convert type 'int' (ContactId) to 'string' (Value). Text = c.Name }; var items = from c in contacts select new ListItem { Value = c.ContactId.ToString(), //Throws exception: ToString is not supported in linq to entities. Text = c.Name }; … Read more

‘No overload for method ‘ToString’ takes ‘1’ arguments’ error occur While Formatting Datetime Field To String ON “dd-MM-yyyy” format

I have been working on asp.net 3.5.I want to Convert a DateTime Data from sqldatareader to a String on "dd-MM-yyyy" Format.
But when I use "dd-MM-yyyy" formatting parameter as "rdMonthlyLeave["LEAVE_DATE"].ToString("dd-MM-yyyy")" browser returns compile error as