Hii
I am attaching the command
SqlCommand cmd = new SqlCommand("select SUM(cast(UserIncomeDetail_Amount as int)) as amount from ft_UserIncomeDetail where User_Uniq='Harish'", con);
con.Open();
sda=cmd.ExecuteReader();
if (sda != null)
{
ViewBag.income = sda["amount"];
}
error-
System.InvalidOperationException: 'Invalid attempt to read when no data is present.'
please the fix issue