N
NuBie via AccessMonster.com
DoCmd.OpenForm "Fuel", , , "[customer] = '" & cboCustomers & "'",
acFormReadOnly
The above code works fine. However, I'm looking for a more efficient way to
retrieve records based on the selection from combo box. The code above
retrieves "ALL" records then filters it. (Retrieves 100 records and shows 15)
I'm thinking of this :
[Forms].[Fuel].[RecordSource] = "SELECT * from Fuel WHERE [customer] = '" &
cboCustomers & "'"
where I want to retrieve ONLY records that meet the criteria. (Retrieves and
shows 15 records) When i tried the second snippet I got a runtime error 438.
Object doesnt support this property or method.
Or is there other way to achieve this? (using a query with params maybe?)
acFormReadOnly
The above code works fine. However, I'm looking for a more efficient way to
retrieve records based on the selection from combo box. The code above
retrieves "ALL" records then filters it. (Retrieves 100 records and shows 15)
I'm thinking of this :
[Forms].[Fuel].[RecordSource] = "SELECT * from Fuel WHERE [customer] = '" &
cboCustomers & "'"
where I want to retrieve ONLY records that meet the criteria. (Retrieves and
shows 15 records) When i tried the second snippet I got a runtime error 438.
Object doesnt support this property or method.
Or is there other way to achieve this? (using a query with params maybe?)