I got the error while populating dropdownlist in Entity Framework.
- private void PopulateFormFieds(int userID)
- {
- UserManager userMgr = new UserManager();
- var result = userMgr.GetUserDetail(userID);
- if (result.Count > 0)
- {
- var user = result.First();
- tbFirstName.Text = user.FirstName;
- tbLastName.Text = user.LastName;
- tbContactNumber.Text = user.ContactNumber;
- }
- else
- {
-
- tbFirstName.Text = string.Empty;
- tbLastName.Text = string.Empty;
- tbContactNumber.Text = string.Empty;
- }
- }
-
- protected void ddlUser_SelectedIndexChanged(object sender, EventArgs e)
- {
- PopulateFormFieds(Convert.ToInt32(ddlUser.SelectedItem.Value));
- }
Operator '>' cannot be applied to operands of type 'method group' and 'int' in
if (result.Count > 0)
Help me to resolve the problem.Thank You.