Is it possible I can have a record open in a form and export that data to a excel template spreadsheet? If so what is the easiest way to do it because im in a beginner level. I will appreciate so much guys!!
You can only transfer data from a table using the transferspreadsheet command when exporting any data. A solution for your problem would be to create a query with all of the fields that you require to be exported and in the criteria of your PK in the query enter the following:
Code:
Forms!YourFormname!YourPKField
Save the query then add a command button to your existing form and use the following code:
Code:
Docmd.outputto acoutputquery, "QueryName"
By using the above code Access will ask you the format you want to export the current record and where you want to save the file, you can alternatively add these to the docmd.outputto command in VBA.