Search by field disappears when i change the lookup table from a TAdotable to a TAdoquery for a TwwDBLookupComboDlg lookup
The Search by Field disappears in the TwwDBLookupComboDlg lookup when the lookup table is changed from a Taotable to a TAdoquery. is there a way to get around this.
The SearchBy combo only shows fields with an available index. The ADOQuery does not have any indexes to order with. You could also try using a TADODataSet instead, although I'm not sure it would work. To try this do the following.
Set the TwwLookupComboDlg.Options so that opShowAllFields is ture.
Then using the OnInitDialog event, add the following code.
procedure TMainForm.wwDBLookupComboDlg1InitDialog(Dialog: TwwLookupDlg);
Roy Woll Thank you for the reply but the main reason i'm using tadoquery instead of tadotable is because everytime i'm using a tadotable "i get a current provider does not support the necessary interface for index functionality" error . How do i work around this error. Most solutions to this problem are dated back to 2005. i am using delphi 10.4 and sql server 15.0.2080.9
Roy Woll yes i have tried your two step suggestion. What it did was the search by box showing but it was empty because they are no indexes with tadoquery. Also do you mean Firedac to acess the data in the first place? I have considered that but it would be done down the line and a separate project on its own.
Please sign in to leave a comment.