> Hi all,
>
[quoted text clipped - 9 lines]
>
> Many thanks, Dean...
there's an example of a form with a textbox at the top and the results
of the sql query in a flexgrid (I think) in the lower portion of the
form. The only difference is that you'd have a field list (combobox
wizard will do this no problem) to get the fields to search. Then
you'd just OR the stuff together, generate your SQL statement, then set
the rowsource for the flexgrid.
pietlinden@hotmail.com - 06 Jun 2006 05:14 GMT
> > Hi all,
> >
[quoted text clipped - 5 lines]
> > terms. Not all of the fields will be searched each time so how would I
> > go about setting this up?
Did you look at the SQL text/results table form in ADH?
I would start there and then maybe use a multi-select listbox to
collect fields to be listed and maybe a subform to collect fields and
values combinations to search. Something like...
<cboFieldList> <cboSymbol> <txtValue>
e.g. <tblLineItems.ItemID><"="><15>
and then you'd end up with...
SELECT...
FROM...
WHERE tblLineItems.ItemID=15;
then you'd assign the flexgrid control's rowsource to the query. (See
ADH).
Essentially, you'd just replace the textbox control with controls to
choose {FieldName, Operator, ComparisonValue}, and then generate the
SQL on the fly, and then assign it to the rowsource of the grid.
Confused? (So am I!!)
Pieter