SpreadWebServcie.UploadContactListFile Method

 

Upload contact list file

Parameters

Parameter

Type

Description

loginEmail

String

The login email of your Spread account.

loginPassword

String

The password of your Spread account or API Key which you can retrieve from your Spread account (My account=> Settings).

fileType

String

Type of upload data, include ".xls", ".csv", ".xlsx".

myFileStream

byte()

The upload file stream ( length<100MB ).

ContactListName

String

The name of contact list.

Return Value

if Uploaded successfully,return string:Spread has received your data and will send you an email after upload complete. (RequestID:123456)

Example

string loginEmail = "Spread@reasonables.com";

string loginPassword = "Spread";

System.IO.FileStream fileStream = new System.IO.FileStream(@"D:\content1.xlsx", System.IO.FileMode.Open);

byte[] arrayByte = new byte[fileStream.Length];

fileStream.Read(arrayByte, 0, Convert.ToInt32(fileStream.Length));

fileStream.Close();

SpreadAPI.SpreadWebService MySpread = new SpreadAPI.SpreadWebService();

string result = MySpread.UploadContactListFile(loginEmail, loginPassword, ".xlsx", arrayByte, "test 20130204");

See Also

SpreadWebService Class | Spread Web Service Namespace