Forums

This topic is locked

SORTING HELP

Posted 09 Apr 2002 23:53:25
1
has voted
09 Apr 2002 23:53:25 Peter Lent posted:
Hi All,

I have a RS that is initially displayed by company name. I want to add the ability to sort by other variables by having the user click a link and then refresh the data on the SAME PAGE.

I know that I could but another page with the sorted data, but I would like to keep it on the same page.

Any suggestions?

THANKS

-Peter

Replies

Replied 10 Apr 2002 00:29:49
10 Apr 2002 00:29:49 Owen Eastwick replied:
Make a link to the same page, something like:

<a href="ThisPage.asp?SortBy=DatabaseFieldName">Sort by This Field</a>

Then set up the recordset something like:

varSort = Request.QueryString("SortBy"

RecorsetName.Source = "SELECT * FROM TableName ORDER BY " & VarSort



Regards

Owen.

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

Edited by - oeastwick on 10 Apr 2002 00:31:05
Replied 10 Apr 2002 20:00:00
10 Apr 2002 20:00:00 Matthijs Horsman replied:
for some more information take a look at ths great tutorial

www.ultradeviant.co.uk/tutorials/tutorial.asp?view=sort_p1

Grrrr
Matthijs
----------------
UD4/WY2K/IIS/ASP-VB
Replied 10 Apr 2002 20:07:25
10 Apr 2002 20:07:25 Peter Lent replied:
Thanks guys, I was able to figure it out with the tutorial listed.

THANKS AGAIN

-Peter

Reply to this topic