|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Checkbox lists
Hi to all
well I'm trying to insert sperated values from a check box list into an sql server database but when I tried to use the property selecteditem.Values in my sql statement it didn't work with me so how to apply this in ASP.NET unsing VB.NET??? Yes I tried both selecteditem.Value and selecteditem.text but what I want is how to insert in separate rows in the DB????????? Last edited by hotel_project : May 21st, 2003 at 01:43 PM. |
|
#2
|
|||
|
|||
|
Try using selecteditem.text instead. Selecteditem.value is a data value you assign the check box that is different from the text value. Did you set that value? If you are in debug mode can you watch selecteditem.value and see if it contains anything?
That's for starters anyway.... |
|
#3
|
||||
|
||||
|
Might wanna check out the SQL "IN" keyword.
e.g.: INSERT INTO foo WHERE id IN (1,2,3) - it allows you to use a list of CSV'd ID's to perform query commands (INSERT, UPDATE, SELECT) - it's very handy |
![]() |
| Viewing: Dev Articles Community Forums > Programming > ASP Development > Checkbox lists |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|