Filling multiple datalist boxes - Newbie 
Author Message
 Filling multiple datalist boxes - Newbie

I am just getting started with SQL 7 and VB6 and have run into a problem.

I have an SQL 7 table called Date_Items with the following fields:

Date_item_num (counter, key field)
person_Id  (foriegn key connected to a person table)
Date_id  (related to a date when an employee is scheduled) - like "19991108"

I have an array of (31) datalist1 boxes on a form Along with an array of
(31) textboxes

I use a for loop (0 to 30) to put the integer representation of the date (as
example "19991108") in each text box right next to each datalist1 box.  So I
feel like I have the ability to index using that number in the data's
Date_id field.

What I want to do is take that index and run a query against the Table
Date_Items that will bring back:
All person_Id 's that correspond to a particular day and INDIVIUALLY place
them in the appropriate corresponding datalistbox1 (0 -30).    Example
Display  3 and 1, in the datalist box if the person with id 3 and 1 are
working.    PS....   I will worry about getting the correct name matched
with the number later.

I once got some results by changing the dayvariable in this select statement
inside my (0 to 30) loop, but it flashed the same data in all the datalist
boxes as it moved through the loop.

adodc2.recordsource = "Select person_id from date_items where date_id = "&
dayvariable &""

Thank you very much for any help you can give.  The sooner you respond, the
more hair you save on my head.

bob alexander



Sun, 28 Apr 2002 03:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. SQL 7 Database Access- filling multiple datalist boxes- Newbie question.

2. Anyone seen bug in subroutine fill of multiple combo boxes

3. Fill in text box on multiple documents

4. Button for filling a fill-In field ? (Newbie)

5. Button for filling a fill-In field ? (Newbie)

6. Button for filling a fill In field ? (Newbie)

7. DataList won't fill???

8. DataList won't fill???

9. DataList won't fill???

10. script newbie - multiple combo boxes

11. Newbie - Multiple columns for list box.

12. Reuse datalist with multiple datasources?

 

 
Powered by phpBB® Forum Software