How do I retrive record values? 
Author Message
 How do I retrive record values?


>I have a datasource component and a table component on my form, along
>with a couple of listboxes.  What I am trying to do is set the index of
>the table component and retrieve the values from a specific field and
>populate the listbox items.  I have been playing with the DBComboBox
>component, but I can't seem to make this work either (at least not the
>way I want it to).

Try this:
Table1.IndexName := 'newindex'; {set index}
Table1.first;                   {goto start of index}

while not Table1.eof do
         Table1.Next;                   {goto next record}

Why not use the DBLookUpCombo???

simply add DataSource and DataField where to post the choosen
information and add LookUpSource, LookUpField and LookUpDisplay
to bring up to list to choose from.

8-D                               it's a funny thing about life ...
Claus Jepsen, Kolding, DK                 if you refuse to accept anything
                                  but the best - you very often get it!
                                ____________Somerset Maugham__

Wed, 09 Sep 1998 03:00:00 GMT  
 [ 1 post ] 

 Relevant Pages 

1. Default Values through Sequences, How is it done?

2. saving a record in a thread doing funnies

3. Doing an action on multiple records

4. manual retrive dbf data

5. Getting old record values on editing TQuery

6. Change values for only one record in a database

7. Retrieve value of autoincrement field with inserted record

8. Re-fetching a posted record, because DB fills in some values

9. Getting Value from current tquery record

10. Getting old record values on editing

11. reading old values before posting ttable record

12. Retriving 2 cursors with StoredProc in Delphi 5.0 from Oracle 8 SQL server


Powered by phpBB® Forum Software