Sync txt file to SkyDrive

ashrafidkaidek

Member
Licensed User
Longtime User
Is there a way to upload / download a txt file to user SkyDrive account? I Now that Microsoft has created a SkyDrive API for android developers, but I’m not sure if this option is available in Basic4Android or not. . .
Thank you all
 

ashrafidkaidek

Member
Licensed User
Longtime User
Erel,

What you are referring to is accessing the user Google related info, but what I’m looking for is accessing the user SkyDrive account (Microsoft related).
It seems to me that the process is pretty much the same . . . but I’m just curious if anybody has successfully tried it before.

helpful link: Configuring your app (Live Connect)

Regards
 

ashrafidkaidek

Member
Licensed User
Longtime User
Erel,

I’m at the point where I need to integrate SkyDrive into my project, I believe I know the process because I have done it multiple times in my windows phone apps, but currently I’m having a hard time understanding how to use “Live SDK for Android” via Basic4Android.

I have followed Microsoft instructions here (Android apps (Live Connect)), and downloaded the SDK as ZIP file, so know how can I convert it to a library to be able to use it in my Basic4Android project?:sign0085:

Any help in this regard will be highly appreciated. Thank you all
 

ashrafidkaidek

Member
Licensed User
Longtime User
Upload text file to SkyDrive Error!!!

I'm trying to upload a txt file to SkyDrive account by using the following code:
HTML:
   Dim job5 As HttpJob
   Dim Link As String = FolderID & "?access_token=" & AccessToken
   job5.Initialize("Job5", Me)
   job5.PostFile(Link, File.DirInternal, "try.txt")

please note that that Link string is the correct location where the file needs to be uploaded in SkyDrive.

"try.txt" is a file created in "File.DirInternal"

when running the above code I'm getting this error:
-----------------------------------------------------
{
"error": {
"code": "request_header_invalid",
"message": "The header 'Content-Type' is missing the required parameter: 'boundary'."
}
}
JobName = Job5, Success = false
Error: Bad Request
-----------------------------------------------------
Based o Microsoft instructions; this is how this task needs to be done:

POST https://apis.live.net/v5.0/me/skydri...n=ACCESS_TOKEN

Content-Type: multipart/form-data; boundary=A300x

--A300x
Content-Disposition: form-data; name="file"; filename="HelloWorld.txt"
Content-Type: application/octet-stream

Hello, World!
--A300x--
-----------------------------------------------------


So i'm a little lost here, any idea what's wrong?:sign0085:
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…