Hi All,
I've only seen simple examples of 'DoCmd.TransferSpreadsheet', so I'm not sure if it can do want I'm trying to accomplish.
I have a directory of Excel workbooks, each with two sheets I need data from. One has the majority of the data I need (columns and columns of data) For the other, I just need the creators name and region from two cells.
I want to bring the main data into a table and then update the table last to fields with the name and region of the owner.
I've never used 'DoCmd.TransferSpreadsheet' and I haven't seen good examples how to use the range property to grab what I want. I figure sorting that out will get me the majority of my data. It's not working, but here's what I have:
Code:
Public Sub PopTb()
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel9, "InfoSecTempTb", "I:\Planning and Technology\RCSA Analyzer\*.lxs", False, a3: ai46 , "Matrix-InfoSec$"
End Sub
For the other two fields I was thinking there must be a way to assign each one to a variable and run an update query, but then I'd have to run that update after every sheet import.
Is there a better way to do this? I thought maybe with ADOD functions, but I can't find anything on it. You ideas would be greatly appreciated.
Kind Regards, Travis