script to upload folders to one drive for buisness
i trying automate uploading files 1 drive business large work via cloud. these files access databases , 2gb piece. script trying run spouploaddownload. see below test , it's results new powershell , appreciated:
-spofolder -uploadfilepath "c:\users\hmagnes\doccuments " -username hmagnes@et-t.com-siteurl "https://easterntelephone-m
y.sharepoint.com/personal/hmagnes_et-t_com/documents" -listname document -folderpath doccuments" -listname document -fol
derpath doccuments
add-spofolder : cannot process argument transformation on parameter 'password'. cannot convert " -username
hmagnes@et-t.com-siteurl " value of type "system.string" type "system.security.securestring".
@ line:1 char:156
+ ... ers\hmagnes\doccuments " -username hmagnes@et-t.com-siteurl "https:// ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ categoryinfo : invaliddata: (:) [add-spofolder], parameterbindingargumenttransformationexception
+ fullyqualifiederrorid : parameterargumenttransformationerror,add-spofolder
ps c:\users\hmagnes>
your code badly copied website.
look closely. "documents" misspelled. code line pasted twice one-inside-the-other.
a normal line this:
# following line add-spofolder -uploadfilepath c:\users\hmagnes\doccuments -username hmagnes@et-t.com-siteurl https://easterntelephone-my.sharepoint.com/personal/hmagnes_et-t_com/documents" -listname document -folderpath doccuments" -listname document -folderpath documents #
\_(ツ)_/
Windows Server > Windows PowerShell
Comments
Post a Comment