Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Conversion from type 'DBNull' to type 'Boolean' is not valid.

Status
Not open for further replies.

bigfoot

Programmer
May 4, 1999
1,779
US
Using a DetailsView. (my last attempt before going back to asp)

How do you bind a check box to get around this error?

Or better yet. Is there any way that I don't have to bind all of my controls inside this DetailsView?

Can I just have full control and read from the db and display, then read from the screen and write to the db?
I'd love that. It's what I'm use to.

I want full control of all my database actions just like a desktop app.

These drag and drop controls frazzle me. LOL


 
Can you use the IsDBNull method to see if you have DBNull, if you don't have it, bind, if not don't bind??



[monkey][snake] <.
 
If you are using the any of the datasource controls, you will find out you loose control of what is going on, that's why I sugges using dataadapters, command objects etc. in code.

You do not have to bind the DetailsView to a datasource.
 
Also, you have NULLs in a boolean column which should never be allowed. Boolean is either TRUE or FALSE and shouldn't be null
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top