Template Macro


Posted by Jeremy on January 09, 2001 6:30 AM

I have created a template using the template wizard. The problem I have is that in order to transfer the data from the template to the database, the user has to save or close out of the template, select "create new record" and click "ok."

Here's my question: Is there a macro or VBA code that can be assigned to a command button that will perform this task automatically. I tried doing just an autosave command, but for some reason, none of the data is transfered. Any help would be great. Thanks!



Posted by GMan on January 09, 2001 9:50 PM


You can create a macro from Tools/Macro/Record New Macro in Excel. Click on Record New Macro, repeat the steps you indicate the user has to do to accomplish the task, then go to Tools/Macro/Stop Recording.
Then Select View/Toolbars/Form and click on the Command Button Option and drop one into your spreadsheet. Attach the macro you created to it and it should do what you want.