Hi all,
(Please forgive, if the problem's description seems a bit longish..)
I plan on using an xDialog box to construct a filter string which in turn could be used 'in front' of a report/Letter/label document (kind of a wrapper).
For an xDialog I have adopted an example from the xDialog tutorial in "A Genie Style Dialog with Tabs" which describes a tabbed dialog using embedded dialogs to show the various tabs containing text box controls where a user can enter filter criteria for the report to be run after the dialog closes.
It's about filtering records from an address table.
On the first tab, there is a key list where the user must first select an 'Instutution' for which he wants to list addresses. This field is a required field and activates the 'Run' button of the dialog after a valid entry is made.
On the second tab, there are two text boxes where the user can enter an 'Organisation' or a 'Name' and
On the third tab, there are text boxes for 'ZIP-Code', 'City' and 'Country' to filter after.
The intention is to add just filled in fields to the filter and to ignore the others, resp. set these parameters to .T.
E.g assuming that the user filled in "Miller" in the name field, plus "4050" in the ZIP-Code field, the resulting filter-string would read "Institution = 'EC' .and. Name = 'Miller' .and. ZIPCode = '4050' "
The dialog as such works.
Where I am stuck is with what to do with the variables, once the user clicks on 'Run'. Even after RTFM I am unsure about which function(s) to use. I got lost somewhere in the quotings :o
How would you tackle this problem? I plan on keeping this xDialog as 'generic' as possible.
Each and every tip very welcome!!
TIA
(Please forgive, if the problem's description seems a bit longish..)
I plan on using an xDialog box to construct a filter string which in turn could be used 'in front' of a report/Letter/label document (kind of a wrapper).
For an xDialog I have adopted an example from the xDialog tutorial in "A Genie Style Dialog with Tabs" which describes a tabbed dialog using embedded dialogs to show the various tabs containing text box controls where a user can enter filter criteria for the report to be run after the dialog closes.
It's about filtering records from an address table.
On the first tab, there is a key list where the user must first select an 'Instutution' for which he wants to list addresses. This field is a required field and activates the 'Run' button of the dialog after a valid entry is made.
On the second tab, there are two text boxes where the user can enter an 'Organisation' or a 'Name' and
On the third tab, there are text boxes for 'ZIP-Code', 'City' and 'Country' to filter after.
The intention is to add just filled in fields to the filter and to ignore the others, resp. set these parameters to .T.
E.g assuming that the user filled in "Miller" in the name field, plus "4050" in the ZIP-Code field, the resulting filter-string would read "Institution = 'EC' .and. Name = 'Miller' .and. ZIPCode = '4050' "
The dialog as such works.
Where I am stuck is with what to do with the variables, once the user clicks on 'Run'. Even after RTFM I am unsure about which function(s) to use. I got lost somewhere in the quotings :o
How would you tackle this problem? I plan on keeping this xDialog as 'generic' as possible.
Each and every tip very welcome!!
TIA
Comment