ExcelToAccessBrokenRanges |
Post Reply |
Author | |
A.D. Tejpal
Microsoft MVP Joined: 30 Jun 2008 Status: Offline Points: 192 |
Post Options
Thanks(0)
Posted: 25 Aug 2011 at 11:37pm |
ExcelToAccessBrokenRanges This sample db demonstrates import of scattered data from excel involving horizontally fragmented data blocks - into a single access table. In such a situation, assigning the data blocks to a common range name, followed by straightforward use of DoCmd.TransferSpreadsheet command does not work. Each data block has to be imported individually, for eventual amalgamation into a single table T_Imported.
Sample excel file (Orders.xls) is located in the home folder that contains this sample db. First row of each data block should carry field names. Simultaneously, a text box located below the list box, gets populated with the cell addresses for respective data blocks. This text box is editable allowing the user to carry out any modification if desired. An option group provides a choice for the mode to be adopted for import action (i.e. whether as per pre-defined ranges or as per user specified addresses). Note: User defined address string using comma as separator between adjacent blocks (no spaces) serves as one of the arguments for subroutine P_ImportFromExcelBrokenRanges. Either of the three sample styles given below can be used (Orders_01 is the name of worksheet): Note: Clicking of Import button carries out the import of different data blocks into temp tables followed by amalgamation into a single table T_Imported. The imported data gets displayed in the subform. Important: Download File >>: uploads/37/ExcelToAccessBrokenRanges.zip |
|
Sponsored Links | Want a good read? Try The Summer of His Life (available on Amazon!) |
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |