Hello - I saw this solution while searching for a solution to my current situation, which is somewhat similar.
Here's the goal: get a daily import of data (daily snapshoot) from a SharePoint list into ms access so that I can run advance reporting
Here's where I am:
What I want to do next:
Here is a note that I found on Microsoft's SharePoint site on importing data using the SharePoint connection:
Hints my reason to the VBA route. Any help?
Here is my start:
Here's the goal: get a daily import of data (daily snapshoot) from a SharePoint list into ms access so that I can run advance reporting
Here's where I am:
- Created an AutoExec to import the SharePoint data daily with 'Scheduled Tasks'
- Named the daily import table "All_yyy_mm _dd" for each day
What I want to do next:
- Append the daily import to a single large table 'MainSharePoint '
- Add an Imported_on_Dat e field to each import to distinguish between the data once it's in the 'MainSharePoint ' table
Here is a note that I found on Microsoft's SharePoint site on importing data using the SharePoint connection:
- Access never overwrites a table in the database as part of an import operation, and you cannot append the contents of a list or view to an existing table.
Hints my reason to the VBA route. Any help?
Here is my start:
Code:
'------------------------------------------------------------
' AutoExec
'
'------------------------------------------------------------
Function AutoExec()
On Error GoTo AutoExec_Err
DoCmd.TransferSharePointList acImportSharePointList, "https://listURL", "{777-777}", "{777-777}", "All_" & Format(Date, "yyyy_mm_dd"), True
' The DetectIdleTime detects if there is no activity, if no activity, ms access will close.
DoCmd.OpenForm "DetectIdleTime", acNormal, "", "", acEdit, acHidden
AutoExec_Exit:
Exit Function
AutoExec_Err:
MsgBox Error$
Resume AutoExec_Exit
End Function
Comment