Q: Find and Seek not working. 
Author Message
 Q: Find and Seek not working.

Hi,
I'm programming data form without showing data control which has DBCombo,
and DBCombo would perform as data control,
I mean whenever dbcAccount changes, other txtBox changes with respect to
Account Name in dbcAccount.

I'm using DBCombo with DAO accessing MS Access,
DBCombo's property as follows,
    DataSource = data1
    DataField = Account Name    'which is primary key in Account Table
    RowSource = data1
    ListField = Account Name

I found that without any code in dbcAccount_change(),
txtAccountType and other text boxes are not changed.

So what I was going to do is to find record in data1.RecordSet,
and populate other textBox with respect to that record.

Problem occures as folloows,
1. data1.RecordSetType = 0-Table    'in property window

err====data1.Recordset.Index = "Account Name" ,  "[Account Name]"   'I tried
both
             data1.Recordset.Seek "=", dbcHostName.Text

Error message said 'Account Name' or '[Account Name]' is not index in that
table.

I tried
    data1.Recordset.Index = "PrimaryKey"
then I got
Object doesn't support this property or method
I press OK twice then
This action was cancelled by an associated object.

2.data1.RecordsetType= 1-Dynaset

    Dim strFind as String
    strFind = "[Account Name] = '" & dbcAccount & "'"
    data1.Recordset.FindFirst strFind

also I got same error...
Object doesn't support this property or method
I press OK once then
This action was cancelled by an associated object.

Could anybody help???
Thanks in advance,
Grumbler



Fri, 17 Aug 2001 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. FIND/SELECT/SEEK Not Working

2. Seeking Tips On Finding Contract Work

3. Seek method not working in 7.0 from 2.0

4. Seek gives data error when not finding text in VB5.0

5. Partial Seek does not work!?

6. index-seek not working

7. index-seek not working

8. Seek Nearest Match if exact match not found ?

9. Seek Method Not Working (new thread)

10. Seek method not found for my ADODB.Recordset object

11. Seek Nearest Match if exact match not found ?

12. Finding a record without Find/Seek methods...

 

 
Powered by phpBB® Forum Software