Android Xamarin.Auth 1.2.2 How to Update Uploaded Cloud Storage File LastModifiedDate?

With Xamarin.Forms, I am using OneDrive SDK on UWP to access OneDrive and it is working good. I am uploading/downloading small data files and I use the following code to change a file's LastModifiedDate:

Item itemUpdate1 = new Item();
itemUpdate1.FileSystemInfo = new Microsoft.OneDrive.Sdk.FileSystemInfo {LastModifiedDateTime = lastModifiedDateTime };
await oneDriveClient1.Drive.Items[item1.Id].Request().UpdateAsync(itemUpdate1);

On Android, I use Xamarin.Auth to access OneDrive and I cannot figure out how to update a file's LastModifiedDate. I am using the following code to sign in and upload the file:

var auth = new OAuth2Authenticator(clientId: clientId, scope: storageScopes1, authorizeUrl: new System.Uri(""),
  redirectUrl: new System.Uri(""));

System.Uri dataFileUri = new System.Uri("" + dataFileName1 + ":/content");
var requestUpload = new OAuth2Request("PUT", dataFileUri, null, account);

I would like to know if OAuth2Request can be used to update the file's LastModifiedDate or if there is another way to do it?
Thanks for your help.

Sign In or Register to comment.