Можно скопировать папку в SharePoint с помощью VBA, и если да, то есть образец кода о том, как это делаетсяиспользование Excel VBA скопировать папку Sharepoint
Большое спасибо
Джеймс
Можно скопировать папку в SharePoint с помощью VBA, и если да, то есть образец кода о том, как это делаетсяиспользование Excel VBA скопировать папку Sharepoint
Большое спасибо
Джеймс
Вы можете publish an Excel file to Sharepoint (aka Chèvre-poing), но это выглядит довольно сложно, так как механизм аутентификации плохо подделан (например, козы).
Так что вы должны сделать, это карту местного Поделиться с Sharepoint (\\my_chevre_poing\goaty\
, то есть немного VBA это сделать из вашего любимого макро место:.
Sub Copy_Folder()
'This example copy all files and subfolders from FromPath to ToPath.
'Note: If ToPath already exist it will overwrite existing files in this folder
'if ToPath not exist it will be made for you.
Dim FSO As Object
Dim FromPath As String
Dim ToPath As String
FromPath = "C:\local\trucs\" '<< your own source there
ToPath = "\\my_chevre_poing\goaty_trucs\" '<< your share there
If Right(FromPath, 1) = "\" Then
FromPath = Left(FromPath, Len(FromPath) - 1)
End If
If Right(ToPath, 1) = "\" Then
ToPath = Left(ToPath, Len(ToPath) - 1)
End If
Set FSO = CreateObject("scripting.filesystemobject")
If FSO.FolderExists(FromPath) = False Then
MsgBox FromPath & " doesn't exist"
Exit Sub
End If
FSO.CopyFolder Source:=FromPath, Destination:=ToPath
MsgBox "You can find the files and subfolders from " & FromPath & " in " & ToPath
End Sub
Вы также можете найти huge resource there