• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1327
  • Last Modified:

Cannot implicitly convert type bool to System.Web.UI.Webcontrols.CheckBox

I am reading data from a table in a database.  The data is a type bool.  When I read the data and then try to display that data on the screen to the user I get this error message.  I oringially used a checkbox to save the data and I am trying to read the data back into the checkbox to show if it was check or not.  Can someone point out what I am doing wrong?

Here is the exact error.
Cannot implicitly convert type 'bool?' to 'System.Web.UI.WebControls.CheckBox'      


here is my code:
cbCT = myProviderReferralQueue.CT;

Open in new window

0
kwh3856
Asked:
kwh3856
1 Solution
 
tillgeffkenCommented:
cbCT.Checked = myProviderReferralQueue.CT;
0
 
kwh3856Author Commented:
Thank you very much.
0

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now