Forums

This topic is locked

Select Specific Records - Urgent

Posted 20 Feb 2003 00:43:00
1
has voted
20 Feb 2003 00:43:00 Mike Peters posted:
I have a repeat region that displays any number of records.

I need to create something that would allow a user to select say record 1, 6, 8, 9, 13 and pass it to another page.

How can I do this?

ASP

Replies

Replied 20 Feb 2003 01:08:21
20 Feb 2003 01:08:21 Owen Eastwick replied:
Put the whole repeat region in a form with the action set to the second page, then create a checkbox with a a value equivalent to the Record ID:

<input type="checkbox" name="chkRecordID" value="<%= RecordsetName.Fields.Item("RecordID".Value %>">

Put a submit button somewhere in the form.

When the form is submited, Request("chkRecordID" will give you a list of values like this: 1, 6, 8, 9, 13


Take a look here for some more info: www.drdev.net/article02.asp

Regards

Owen.

-------------------------------------------------------------------------------------------
Used programming books and web development software for sale (UK only): www.tdsf.co.uk/tdsfdemo/Shop.htm

Developer services and tutorials: www.drdev.net

Multiple Parameter UD4 / Access 2000 Search Tutorial: www.tdsf.co.uk/tdsfdemo/
Replied 21 Feb 2003 16:43:36
21 Feb 2003 16:43:36 Mike Peters replied:
That is a great aritcle but it is used for deleting a record. Meaning, delete record where your request is =

I just want to pass the selected records and display them again. Almost like adding items to a shopping cart.
Replied 21 Feb 2003 17:08:03
21 Feb 2003 17:08:03 Mike Peters replied:
I think I will try and conver the DELETE statement over to a select statement.

My other problem is that my recordsets are filtered by a multiple parameter search form. So, I have like 5 recordsets that I will need to be able to pass information from.
Replied 21 Feb 2003 17:32:31
21 Feb 2003 17:32:31 Owen Eastwick replied:
You can use a very similar method to set up a SELECT Statetement:

SELECT Field1, Field2, Field3 WHERE RecordID IN (1, 2, 5, 9)

Regards

Owen.

-------------------------------------------------------------------------------------------
Used programming books and web development software for sale (UK only): www.tdsf.co.uk/tdsfdemo/Shop.htm

Developer services and tutorials: www.drdev.net

Multiple Parameter UD4 / Access 2000 Search Tutorial: www.tdsf.co.uk/tdsfdemo/

Reply to this topic