Isaac
Lifelong Learner
- Local time
- Yesterday, 22:23
- Joined
- Mar 14, 2017
- Messages
- 8,738
I am getting Invalid Argument on TransferText. Unfortunately this table does have multi-valued fields--only because it is linked to a Sharepoint list with People fields, which I could not control.
If I run TranferText with no saved specification name, it works fine. But I had saved a spec with special delimiter and text quoting characters, now it barfs.
Is this just another thing I can't do with MV fields for some odd reason?? GRRRRRR -10 for sharepoint!
If I run TranferText with no saved specification name, it works fine. But I had saved a spec with special delimiter and text quoting characters, now it barfs.
Is this just another thing I can't do with MV fields for some odd reason?? GRRRRRR -10 for sharepoint!
Code:
Sub BackupSharepointTables()
Dim strPathDist As String, strPathReview As String, strLine As String, x As Long, fld As DAO.Field
strPathDist = "U:\folder\BACKUPS\SP TABLE BACKUPS\DistributionPortal_" & Format(Now, "YYYY-MM-DD HHMMSS") & ".txt"
strPathReview = "U:\folder\BACKUPS\SP TABLE BACKUPS\ReviewAndChallengePortal_" & Format(Now, "YYYY-MM-DD HHMMSS") & ".txt"
DoCmd.TransferText acExportDelim, SpecificationName:="spec_Backup_ExportDIST", TableName:="Distribution Portal", FileName:=strPathDist, hasfieldnames:=True
DoCmd.TransferText acExportDelim, SpecificationName:="spec_Backup_ExportRCP", TableName:="RCP", FileName:=strPathReview, hasfieldnames:=True
MsgBox "Done", vbExclamation, " "
End Sub