Hello,
I have a table called Control_File, which stores Start_Date, End_Date and Div_Nbr. I built a form using the Create Form Wizard and selected the Start_Date and End_Date fields. Next I added a button to the form and used the visual basic editor to automatically loop through a set of queries when the button is clicks and output the results to an Excel spreadsheet.
The problem I am having is, when I type in the Start_Date and End_Date it doesn't update the Control_File table unless I scroll to the next record and back before clicking the button. If I click the button without scrolling forward and back, the queries run for the previous date range. How can I make sure that when I click the button it will update the Start_Date and End_Date in my Control_File table before running the queries?
I have a table called Control_File, which stores Start_Date, End_Date and Div_Nbr. I built a form using the Create Form Wizard and selected the Start_Date and End_Date fields. Next I added a button to the form and used the visual basic editor to automatically loop through a set of queries when the button is clicks and output the results to an Excel spreadsheet.
The problem I am having is, when I type in the Start_Date and End_Date it doesn't update the Control_File table unless I scroll to the next record and back before clicking the button. If I click the button without scrolling forward and back, the queries run for the previous date range. How can I make sure that when I click the button it will update the Start_Date and End_Date in my Control_File table before running the queries?