ASP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsProgrammingASP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old October 3rd, 2003, 12:52 PM
yessir's Avatar
yessir yessir is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 458 yessir User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 h 9 m 56 sec
Reputation Power: 6
Send a message via ICQ to yessir Send a message via MSN to yessir
Question generating list

How do I get one list to alter the contents of another

I have a table category with

id
category_name
active_indr

and another publications with

lv
publication_name
active_indr

The category chosen in a list has an id.

I then want the next list to contain all publication_name's where category.id = publications.id AND publications.active_indr=-1

How can I do this, and without having to reseting the page if possible?

PLEASE HELP
thanks in advance

Reply With Quote
  #2  
Old October 3rd, 2003, 03:59 PM
evolve_iris evolve_iris is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Location: Dubai, UAE
Posts: 15 evolve_iris User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 m 21 sec
Reputation Power: 0
Send a message via ICQ to evolve_iris Send a message via Yahoo to evolve_iris
www34.brinkster.com/emlebanon/jsparrow/countrylist

hey yessir

Nice nick. So when I need to address you, I HAVE TO say sir yessir

Now, you'll find what you need here


Country - Cities List - The right way to do it

Pick a country which then populates the cities field dynamically accessing the database in a second window and without refreshing the page.

FULL SOURCE CODE AVAILABLE FOR FREE DOWNLOAD

If you do use the script then Id love if you ad a credit to me

cheers
Shyam Gopinath

Reply With Quote
  #3  
Old October 6th, 2003, 08:45 AM
yessir's Avatar
yessir yessir is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Posts: 458 yessir User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 h 9 m 56 sec
Reputation Power: 6
Send a message via ICQ to yessir Send a message via MSN to yessir
Unhappy thanks

unfortunatley i came across this already...

well it's not unfortunate that i came across it, but rather that it is not easy to implement for me.

I am new to ASP and such it is a little confusing, as well the use of variable names is overwhelming in this code as far as I need to go.

As well I am on a time constraint and find it hard to change to what I need... I only have a little time to do this (work term).

Is there anyway to shorten the code as to the sole implementation of the processes as far as the 2 lists go?
There is a LOT of overkill in the code...

OR is there another way? I say the use of filters on another site, is there a way to capture the value of a selected list item into a variable and use it to filter?

Code:
Const adFilterNone = 0
Const adFilterPendingRecords = 1
Const adFilterAffectedRecords = 2
Const adFilterFetchedRecords = 3
Const adFilterConflictingRecords = 5
  
Dim oRS, strSQL, strConn

	Set oRS = Server.CreateObject("ADODB.RecordSet")
	strConn = "Provider=Microsoft.Jet.OLEDB.4.0;" _
		&"Data Source=C:\Data\FPNWIND.mdb;"
	strSQL = "SELECT * FROM Products"
	
	oRS.Open strSQL, strConn, 3, 3
	
	oRS.Filter = "UnitPrice < $20.00"
	
	'Recordset contains
	'Only Records Where the Unit Price is Less than $20
	Do While Not oRS.EOF
		Response.Write(oRS("CategoryID") & "<BR>")
	oRS.MoveNext
	Loop
	
	‘Remove Filter
	oRS.Filter = adFilterNone
	'RecordSet Now Contains All Field Data again
	
	oRS.Filter = "SupplierID = 10"

	'Recordset contains
	'Only Records Where the Supplier ID is 10
	Do While Not oRS.EOF
		Response.Write(oRS("CategoryID") & "<BR>")
	oRS.MoveNext
	Loop
	
	oRS.Close
	Set oRS = Nothing

Last edited by yessir : October 6th, 2003 at 08:54 AM.

Reply With Quote
  #4  
Old October 7th, 2003, 05:26 PM
evolve_iris evolve_iris is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Oct 2003
Location: Dubai, UAE
Posts: 15 evolve_iris User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 m 21 sec
Reputation Power: 0
Send a message via ICQ to evolve_iris Send a message via Yahoo to evolve_iris
oh yessir,

im sorry, my fault. the code is a document template i confess.

give me some time im really tied up. if you figure it out though, do post it here so other users can see it

cheers
shyam gopinath

Reply With Quote
Reply

Viewing: ASP Free ForumsProgrammingASP Development > generating list


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
Stay green...Green IT