ASP, Access, Checkbox, Multiple Delete

I have to develop a page where, based on status some records are selected from the Access database and displayed. A checkbox is displayed beside every record.

Some checkboxes can be selected and the corresponding record should be deleted if the delete bottun is pressed.

I know how to select the records from the database and perform multiple delete. But do not know how to link the database and the checkboxes. Anybody has any ideas??

View Replies


ADVERTISEMENT

Asp: Delete Using Checkbox

I have an asp page that will delete using checkbox. This checkbox I have assigned the username field as the delete refference.

value="'<%=viewLec("username")%>'">

But now..I want to assign an no field to the checkbox as the delete refference, but it did not works!!!

value="<%=viewLec("no")%>">

I think it has to do something with my delete sql command! Code:

View Replies View Related

Multiple Checkbox Only Passing One Value

I have a series of checkboxes:

<td><input type="checkbox" name="reportTo" value="Rob"></td>
<td><input type="checkbox" name="reportTo" value="John"></td>

etc...

but I only get a value passed to the database if just one is selected. If more than one is selected, no value is returned. I thought the value passed was s'posed to be a comma delimited string of all checked boxes?

View Replies View Related

Add Multiple DB Entries By Checkbox

There are a lot of references on the net on how to delete multiple entries in a database by using a checkbox. What I would like to do is add a checkbox to the output of a query (ie. bunch of names).

Then be able to select some of the names by clicking on a checkbox and when submitted, add those checked names to another database (insert). Similar to a shopping cart selecting multiple products but when submitted, it does not add them to the checkout, it adds them to a database as new inserts.

View Replies View Related

Multiple Insert With Checkbox...

This is my problem... its for a mailing list with categories...

I have 3 table...

1 : Name,City,Email

2 : Categorie

3 : Name_id , Categorie_id

So when a user fill up the mailing list form, he can check as many categorie he want...

but how i can insert 1 row in my table #3 for each checkbox checked...

Can someone post me a simple script...

View Replies View Related

Updating Multiple Records Thru Checkbox

I need a code that will update multiple records on a list thru checkbox.

If the record is selected, the details that was updated on the selected
record will copy the same value as what is updated.

View Replies View Related

Persits.Upload.1 And Multiple Checkbox

I have an ASP script which is used to upload files with Persits.Upload.1 object. But I can't get the values from mutliple checkboxes in the form like normally.

<form method="post" ENCTYPE="multipart/form-data"....>
<input type="checkbox" name="language" value="English">English
<input type="checkbox" name="language" value="Spanish">Spanish
<input type="checkbox" name="language" value="Chinese">Chinese ....

View Replies View Related

Delete Multiple Records

I read this article below and play around with delete multiple records function in dreamweaver. Assume that all my database fields setup are exactly like the code below. I was able to follow the instruction and did everything excepted line# 29. Can someone give me a suggestion of the line# 29 suppose to be (in example if possible).....

View Replies View Related

Multiple Delete Using Checkboxes

I have created my own web mail system, and when the user has mail is automatically inserts it into a database. Now I need to be able to allow the user to delete the mail, either 1 or more at a time.

I have two select boxes, ones the option of what to do with the selected mail. Then I have another box which is only for the likes of moving mail to a different folder ( ie personal folders ).

Now When I select the mail I want to delete, then select Delete from the drop down box and then press submit, It should then loop through all the selected items and then delete them.

But when I try it doesn't delete them and doesn't provide an error, then I looked into it and used this: Code:

View Replies View Related

Multiple Record Delete

I have written an events diary for a client .. and they wish to have a system of multiple deletes so they simply use a check box to select the items to delete and then hit a button to remove the selected records form the database. as all iget is scripting errors. Is there a simple way to do this?

Someone advised me to use an IN statement to Delete multiple records, but all I get is :

Error Type:

Microsoft OLE DB Provider for ODBC Drivers (0x80040E14)
[Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'ID In ()'.

I have followed several different tutorials but I get the same outcome! It doesn't seem to like the IN statement.... any ideas anyone ???

View Replies View Related

Persits.Upload - Submitting Multiple Checkbox

I am using a form to upload images with Persits.Upload object. Now my problem is I cant use multiple checkboxes in the form.

In general forms I can use Form("checkboxName").Count to get the number of checkboxes selected and use Form("checkboxName")(i) to retrieve the value of each check box.

This doesnt work with Upload.Form

View Replies View Related

Multiple Delete Of Files With FSO Error

I try to do a multiple delete of files through FileSystemObject, but after deleting the first file, ASP gives me a "Permission denied" error. Below you see my code:

Set fso = CreateObject("Scripting.FileSystemObject")
For Each Item in Request.Form("filename")
delFile = path2 & "files" & Item
fso.DeleteFile delFile
Next

View Replies View Related

INSERT Multiple Records From Checkbox Form With Unique Ids

I have an .asp page with a form to copy job responsibilites form one
job to another. It is a hotmail type interface with checkboxes
besides each responsibility. After submitting, it should copy the
selected resp's to a different job. After that it should renumber
that job's responsibilities.

This is the code I am using now to copy:

copySQL4 = "INSERT INTO
jambue.RESP(POSCODE,IDCODE1,IDCODE2,RESP_NUM,RESP) SELECT '" & id & "'
POSCODE,'" & dept & "' IDCODE1,'" & unit & "' IDCODE2, '999' RESP_NUM,
RESP FROM jambue.RESP WHERE (POSCODE = '" & POSCODE & "' AND IDCODE1 =
'" & sourceDept & "' AND IDCODE2 = '" & sourceUnit & "') AND RESP_NUM
IN (" & Request.Form("chk") & ")"

As you can see the value '999' is hardcoded in there as the new
Responsibility Number to go with the copied responsibility. I use
this because there are no jobs with that many responsibilities. This
works fine if I only select one resp. to copy over. But if I select
more than one that part still runs fine but I get an error with the
below. It says too many rows would be affected. Of course, this must
be because there are now at least 2 responsibilites with the same
RESP_NUM. Code:

View Replies View Related

How To Delete Multiple Records Using A Series Of Checkboxes

Does anyone know how i could print multiple records in a database using a series of check boxes on a webpage? i.e it prints all the records that have been ticked?

View Replies View Related

Searching Multiple Memo Fields In Multiple Tables In Access

I have a search option on my website, which should perform a search on 4 fields, as follows:

tblNews
headline
content

tblDatabank
filename
description

It only needs to return matches which are an exact match of their search criteria. For instance, searching for "I am here" would return a record which contained "I am here", but not just "I" or "I am" etc.

I need to return all these records as part of one recordset preferably, as I want to be able to order them etc., though I imagine you may suggest I use an array somehow to merge two recordets etc., then reorder them?

View Replies View Related

ASP Checkbox Default Checked From Access

I have a contact list in an Access database.

I have a table that contains contacts a table that contains categories and a third table that is a join table that assigns users to categories in a many-to-many relationship.

I have a script that creates a series of checkboxes from the categories table so when a new contact is added the user can select multiple checkboxes, categories, to place the user into.

I want to be able to edit a contact by clicking their name that takes them to a ContactUpdate.asp form that is already filled with all of the values for the contact. Their name, address, phone number etc. however I want the checkboxes,categories, that the contact is already in to be selected on the ContactUpdate.asp page.

I need the user to know what categories the contact is already in.

Here is the code I already have that creates the checkboxes. When a contact is added so I'm sure the contact update will be some variation: Code:

View Replies View Related

SQL Statement For Creating A Checkbox In Access

Can anyone tell me the SQL statement for creating a Yes/No checkbox column in Access.

View Replies View Related

Form Checkbox Access Yes/No Field Entry

i have a checkbox Code:

<input class="txtbox" type="checkbox" name="C1" value="ON">

it will correspond to a field in my ms access database that has a Yes/No data type. when the box is ticked, i would simply like the value Yes to be entered into the database..

i enter other elements of my form (a input text box for example) using Code:

rsAddComments.Fields("area") = Request.Form("area")

so what would the entry code look like similar to this.. and what would the for checkbox code look like?

View Replies View Related

Updating Multiple Tables In Ms Access And Asp

I have an query that gets value from two tables lets say tb1 and tb2. First i m tryin to insert values into tb1 and based on those values i have to update some already existing values in tb2. it gives me following error:

Provider for ODBC Drivers error '80004005'
Cannot update. Database or object is read-only

i know my cursur types are correct as i can update without any error with a single table. This leads me to wonder if updating multiple tables in access is possible?

View Replies View Related

Multiple Insert Into Access Database

I need to insert into an access table multiple times i know how to insert 1 item but not multiple times.

View Replies View Related

"OR" Access Query From ASP (via Checkbox)

The setup:
Access database of vendors. A vendor can offer one or more services.

ASP page provides user a checkbox of services. User clicks one or more options and submits. The database should return all vendors that match the services selected.

No dice. I can of course easily pull up vendors that match one service. But the multiple options are treated as an AND search. I don't want to find only vendors that provide all the services checked, but all the vendors that provide one or more of the services selected by the user.

I have tried stored procedures in Access and SQL statements. I either get data type errors or nothing found.

View Replies View Related

Handling Errors From Multiple Requests To Access Database

When simultaneous requests to open an Access Database occur, the Jet Database engine returns an error stating: Cannot Open file, already in use.

I know this occurs because I'm using a file-based Access database, and it's locked while data access is taking place. However, at this time, its the only platform available on the site.

My question is, can I somehow use an On Error GoTo Blah statement to catch the error, clear it, and then attempt the ADODB.Connection.Open statement again?

View Replies View Related

Exporting Data From Ms-access To Multiple Excel Worksheets

How to export data from ms-access database to excel worksheet. mainly i need to export data to multiple worksheets. it is very urgent to us.

View Replies View Related

Query Access With Multiple Query

I am using ASP/MS ACCESS to see how I can query the same database, via 2 formfields.

{name: - search}Textfield 1: - Search by Category
AND/OR By
{name: - searchT}Textfield 2: - Location

Currently,

strSearchwords = Trim(Request.QueryString("search")); where "search" is the name of Textfield1

Which is fine, but how can I set it so that on Submit, the string from search, and searchT are somehow joined together into one string?

View Replies View Related

SQL Server - Update/Insert Multiple Cols Into Multiple Tables

Just as the title says I am trying to do something impossible with a single SQL statement. I am doing an ASP webpage for internal use at the company I work for.

I want to know if there is a way to insert/update data into multiple tables in 1 SQL statement.

If it requires functions | views or anything else that is fine but I don't want to have 3-4 different SQL statements to update 2-3 different columns in different tables.

View Replies View Related

How To Update Multiple Records With Different Multiple Value

i hav problem with updating the data. In the asp page i hav displayed records based on search criteria. in display mode im displaying the to be updated field in combo box for each similar contract_no. each contract_no will hav different no of rows and to be updated combo box.

based on the selected value in the combo boxes of different contract_nos i hav to update the combo value with old value. user select multiple combo values at a time I need anybody's help with detailed programming logic.

View Replies View Related

Checkbox Value?

is there a way of having a dropdownlist and a text field with a checkbox so that you can check a box and have the vaule assigned from a option selct list or check another box and have the value assigned from a textfield?

View Replies View Related

Asp And Checkbox

I would like to make an interaction with a database using ADO and SQL. I would like to display some parts of the database using checkboxes to choose the different parts. But I don't know how to build the SQL command in fuction of which checkbox is checked.

View Replies View Related

Checkbox Value

how to write sql to give value true in db?

View Replies View Related

If Else Using Checkbox Value

I have a checkbox which is used to determine whether or not the user wants to display a map of their business with their listing the value of which is being written into a database.

When I am outputting the listings I am just trying to use a simple if else statement

i.e. If(ShowMap = true)Then
Response.Write("<td>Show Map</td>")
Else
Response.Write("<td>No Map</td>")
End If

Problem is I know the database contains different values for ShowMap i.e. some true, some false. Yet when I use this code, No Map is output for all records.

View Replies View Related

Using A Checkbox

I have a profile search where people can search through our dating profiles. I want to add a checkbox which when checked filters out those records where the recordfield pictures is empty.

I have problems figuring out what the checked value of the checkbox should be and how to use the information from the checkbox in the searchresults page to build the record set. For understanding, if a user does not have a picture the picture field is empty.

View Replies View Related

Value In Checkbox

I am trying to display the value of a true/false value in my table through the use of the following:

<input type=checkbox name=FieldLabCheck value=" &
objRecordset("FieldLaborSuper") & "></input>

it doesn't work though.... what am I doing wrong.

View Replies View Related

Value Of Checkbox

I have a checkbox in a form from which I want to collect the value.
<input type="checkbox" name="Question11a" value="a">

In the asp page that is called on submit of the form, I declare a variable, iQuestion11a, and request the value of this checkbox:
iQuestion11a = Request("Question11a")

When I print out the value to an html page <% response.write(iQuestion11a) %> it is empty.

View Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved