Advertisements

IronPython: File upload to Sharepoint PDF Print E-mail
Tuesday, 08 June 2010

So easy and works fine with proxy.

def upload2sharepoint(host_target,source_file):
    # (.Net) upload to Sharepoint...
    # it's that easy!

    wc = System.Net.WebClient()
    wc.Credentials=System.Net.CredentialCache.DefaultCredentials
    bytes = System.IO.File.ReadAllBytes(source_file)
    wc.UploadData(host_target,'PUT',bytes)


Download the full script , a work in progress, with logging, etc...
 
< Prev   Next >
Images ©Copyright 2009-2011 C. Nichols. Hosting by Dreamhost

download joomla cms download joomla cms