Hi Access Programmers!
I am in a bit of a predicament. I have a form with a command button which runs a macro which generates a report and exports it as a pdf, this is based on a date range and some other critera. However, before this report is generated I would like to check a table for data in the date range specified in the form and prompt user input if there is no data in that date range. Checking if the data is in the table I have done using a simple DCount and then I kill the macro with some basic VBA attached to the button. My question is what would be the best way of getting the user to input the data into table? Would it be using a form? If so how can I make a form be prepopulated with say 4 sets of information i.e. Site, Date, TruckCount (By pre-populated I mean for the fields I'm entering the data into to already have values in them as there will only be one field which is unknown for each row in the table). Also it is probly worth noting the maxium number of rows for each month is 4.
I am in a bit of a predicament. I have a form with a command button which runs a macro which generates a report and exports it as a pdf, this is based on a date range and some other critera. However, before this report is generated I would like to check a table for data in the date range specified in the form and prompt user input if there is no data in that date range. Checking if the data is in the table I have done using a simple DCount and then I kill the macro with some basic VBA attached to the button. My question is what would be the best way of getting the user to input the data into table? Would it be using a form? If so how can I make a form be prepopulated with say 4 sets of information i.e. Site, Date, TruckCount (By pre-populated I mean for the fields I'm entering the data into to already have values in them as there will only be one field which is unknown for each row in the table). Also it is probly worth noting the maxium number of rows for each month is 4.