Ive got a report, where in certain circumstances I need to display some text boxes at the bottom.
So, Ive got a subroutine that runs a query. If that query contains data, then I make the text boxes visible, and populate them.
If that query contains no data, then I make the text boxes disappear.
If I call this code from the Report_OnLoad event, then nothing happens (apart from an error, as the record id has not yet been initiated)
If I call it from the OnActivate, then it runs, and if I preview the form, it runs and populates the data. However, if I do this in the live applcation, nothing happens (Im not even convinced that the OnActivate method is being called, as the report is generated and sent immediately to the print queue.
So, whats the best strategy of programatically populating some form values, based on a query.
Am I going to have to do an outer join, and populate the text boxes as part of the main form query? (I say outer, as there may not be data in the table that I use to populate the textboxes!)
Hope thats all self explanatory
K
So, Ive got a subroutine that runs a query. If that query contains data, then I make the text boxes visible, and populate them.
If that query contains no data, then I make the text boxes disappear.
If I call this code from the Report_OnLoad event, then nothing happens (apart from an error, as the record id has not yet been initiated)
If I call it from the OnActivate, then it runs, and if I preview the form, it runs and populates the data. However, if I do this in the live applcation, nothing happens (Im not even convinced that the OnActivate method is being called, as the report is generated and sent immediately to the print queue.
So, whats the best strategy of programatically populating some form values, based on a query.
Am I going to have to do an outer join, and populate the text boxes as part of the main form query? (I say outer, as there may not be data in the table that I use to populate the textboxes!)
Hope thats all self explanatory
K