Ask a Question related to ASP Database, Design and Development.
-
Leif Hauge #1
Adding record to MDB
I have a problem with adding a record to my MDB database. I know how to add
products, but as soon as I use a checkbox to add "selected" or "not
selected", I get the message "Error desc. -> [Microsoft][ODBC Microsoft
Access Driver] Data type mismatch in criteria expression."
How do I add a checkbox value into my MDB database ? I have chosen a
"YES/NO" value to my field, and the rest of the fields worked before adding
this checkbox.
Best regards
Leif
Leif Hauge Guest
-
Adding record
I have a database the I add a new candidate in and as you're adding the information for the candidate other boxes pop up to add deatils (personal... -
Stop adding record in subform after record count = 1
Can someone help in in what to put after the THEN statment to allow one entry if the Record count is =>1 in the Before insert or should I set the... -
Adding a new record when the record source is a query.
Hello All, I have a form that runs a query. The reason it runs on a query is because prior to it opening I have a form from which you can pick... -
Adding record to a MYSQL DB using PHP ?
What is the best way to add a new record to a MYSQL DB using a FORM and PHP ? Any examples or URLS ? Thanks -
adding a new record with code
Access 97 ,win98SE. I have a form (myform) with a subform(mysf). myform has a combo box which looks up a client and then displays that client... -
Ken Schaefer #2
Re: Adding record to MDB
>> The error is on line 8
Exactly!> How do you know? I didn't post any code
Cheers
Ken
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"Leif Hauge" <leif76@online.no> wrote in message
news:%236b$rQFRDHA.3796@tk2msftngp13.phx.gbl...
: I have a problem with adding a record to my MDB database. I know how to
add
: products, but as soon as I use a checkbox to add "selected" or "not
: selected", I get the message "Error desc. -> [Microsoft][ODBC Microsoft
: Access Driver] Data type mismatch in criteria expression."
:
: How do I add a checkbox value into my MDB database ? I have chosen a
: "YES/NO" value to my field, and the rest of the fields worked before
adding
: this checkbox.
:
: Best regards
: Leif
:
:
Ken Schaefer Guest
-
Bob Barrows #3
Re: Adding record to MDB
Mosley wrote:
Not necessarily. A checkbox either returns the word "on", or whatever word> "Leif Hauge" <leif76@online.no> wrote in message
> news:%236b$rQFRDHA.3796@tk2msftngp13.phx.gbl...>>> I have a problem with adding a record to my MDB database. I know how
>> to add products, but as soon as I use a checkbox to add "selected"
>> or "not selected", I get the message "Error desc. ->
>> [Microsoft][ODBC Microsoft Access Driver] Data type mismatch in
>> criteria expression."
>>
>> How do I add a checkbox value into my MDB database ? I have chosen a
>> "YES/NO" value to my field, and the rest of the fields worked before
>> adding this checkbox.
>>
>> Best regards
>> Leif
>>
>
> don't use 'yes no',
>
> use a text field,
>
> a check box enters the word 'on'
you have set its value property to.
You can use a checkbox. Just use an If statement to process the user's> into the database or nothing if it
> is not checked.
input. If the user checked the box, then its value will have a length
greater than 0:
Dim ChkBoxValue
ChkBoxValue=request.form("CheckBox")
If len(ChkBoxValue) > 0 then
ChkBoxValue = -1
else
ChkBoxValue = 0
end if
Now pass the value contained in ChkBoxValue to your SQL statement.
HTH,
Bob Barrows
Bob Barrows Guest



Reply With Quote

