AlphaJohn
Honorary Master
- Joined
- Sep 10, 2012
- Messages
- 14,636
1st off I am not an expert and a little rusty in my code. I just need help with a simple problem adding a single feature to a clients Access aplication.
They have an internal Access aplication and want to be able to import data from Excel instead of coping the data manually everytine.
Database consist of
tblHead <-- form headder
tblData <-- subform
With One to many relation and link is an AutoID stored in the Subform
From ancent memory I know I have to import the data into a table and then transfer it to the subform. What I forgot is the SQL command to INSERT/APPEND the data into the subform
I can get the data into a table fine with
All I need is to get TempData into the current Subform with the same AutoID link.
Any ideas cause either google or myself is useless? (I even went to page 2 on multiple search results with no luck)
Sample database and Excel file over here if it may help.
They have an internal Access aplication and want to be able to import data from Excel instead of coping the data manually everytine.
Database consist of
tblHead <-- form headder
tblData <-- subform
With One to many relation and link is an AutoID stored in the Subform
From ancent memory I know I have to import the data into a table and then transfer it to the subform. What I forgot is the SQL command to INSERT/APPEND the data into the subform
I can get the data into a table fine with
Code:
Private Sub Command7_Click()
DoCmd.DeleteObject acTable, "TempData"
DoCmd.TransferSpreadsheet acImport, , "TempData", "c:\test\test.xlsx", True
End Sub
All I need is to get TempData into the current Subform with the same AutoID link.
Any ideas cause either google or myself is useless? (I even went to page 2 on multiple search results with no luck)
Sample database and Excel file over here if it may help.