Import Macro Code Into Another Spreadsheet. Click the Developer tab and then click the Macros button. Excel displays the Macro dialog window that contains a list of the spreadsheet's macros. Step 2. Click on the macro you want to import into another spreadsheet, and then click Edit to open the Visual Basic Editor.A Project window containing a list of modules appears on the left; a Code window containing the macro's VBA code appears on the right. Step 3.lick on the macro you want to import into another spreadsheet, and then click Edit to open the Visual Basic Editor.
Import Data Into Excel. There are many instances we need to import data into Excel. The most commonly known method is to use export the data from the database in CSV or text form and then open the exported file in Excel. This method will put the data into an Excel worksheet. The data will remain unchanged.  Open the workbook that contains the module that you want to copy and the workbook that you want to copy the module to. On the Developer tab, in the Code group, click Visual Basic. This starts the Visual Basic Editor. In the Visual Basic Editor, on the View menu, click Project Explorer. A macro is an action or set of actions that you can use to automate tasks. You can record macros by using the Record Macro command (Developer tab, Code group). Macros are recorded in the VBA programming language. Import and Export VBA code. Copy the code in a Standard module of your workbook, if you just started with VBA see this page. Where do I paste the code that I find on the internet. On this page you find some basic VBA code to Import and Export VBA code in Excel for Windows. Copy every macro and function below into a Standard module of a new workbook and save this Import-Export file as xls or xlsm. In the VBE Editor set a reference to  Microsoft Visual Basic For Applications Extensibility 5.3  and to  Microsoft Scripting Runtime  and then save the file. Set rs = Nothing. cnn.Close. Set cnn = Nothing. Exit Sub. End Sub. Step 3: Click the Run button or F5 (Also you can insert a button/shape in excel sheet then right click and assign this macro to run everytime.). Access DB records have been successfully downloaded to Excel, Open your Excel workbook and check the data.  Overview of macros and VBA. If you are unfamiliar with macros and VBA in general, you may find the following information helpful. A macro is an action or set of actions that you can use to automate tasks. You can record macros by using the Record Macro command (Developer tab, Code group). Macros are recorded in the VBA programming language. You can inspect and edit your macros in the Visual Basic Editor, a window that is opened by Exce The VBA code. Copy every macro and function below into a Standard module of a new workbook and save this Import-Export file as xls or xlsm. In the VBE Editor set a reference to  Microsoft Visual Basic For Applications Extensibility 5.3  and to  Microsoft Scripting Runtime  and then save the file. Import Macro Code Into Another Spreadsheet. Click the Developer tab and then click the Macros button. Excel displays the Macro dialog window that contains a list of the spreadsheet's macros. Step 2. Click on the macro you want to import into another spreadsheet, and then click Edit to open the Visual Basic Editor. A Project window containing a list of modules appears on the left; a Code window containing the macro's VBA code appears on the right. Step 3. 1 Choose Import And Export from the File menu. 2  To export to Access or Excel, select the Export To A File option and click Next. 3  Choose Microsoft Access (or Microsoft Excel) and click Next. 4  Select the folder you want to export, as shown in Figure A, and click Next. 1 To export to Access or Excel, select the Export To A File option and click Next. 2  Choose Microsoft Access (or Microsoft Excel) and click Next. 3  Select the folder you want to export, as shown in Figure A, and click Next. 4  If you select a folder with subfolders, the wizard also exports the items in the subfolders. Step 4. Press Alt-Q to close the Visual Basic Editor and return to your spreadsheet in the main Excel window. Step 5. Open the worksheet into which you want to import the macro code you copied. Click the Developer tab, then click the Visual Basic button to open the Visual Basic Editor. Step 6. Click Insert and select Module.. The editor creates a new module that contains your macro as well as a new Code window that is blank. Click on the macro you want to import into another spreadsheet, and then click Edit to open the Visual Basic Editor. A Project window containing a list of modules appears on the left; a Code window containing the macro's VBA code appears on the right. Step 3.
http://www.advanced-excel.com/import_data.html https://support.office.com/en-us/article/copy-a-macro-module-to-another-workbook-13c0938b-8432-4259-9177-a71f7e626de0 http://www.rondebruin.nl/win/s9/win002.htm http://www.askeygeek.com/vba-code-to-import-access-tablequery-data-to-excel/ https://support.office.com/en-us/article/copy-a-macro-module-to-another-workbook-13c0938b-8432-4259-9177-a71f7e626de0 http://www.rondebruin.nl/win/s9/win002.htm http://smallbusiness.chron.com/import-macros-excel-54777.html http://www.techrepublic.com/blog/how-do-i/how-do-i-export-e-mail-messages-to-access-using-vba/ http://smallbusiness.chron.com/import-macros-excel-54777.html
how to import records below using excel macro