Click here to Skip to main content
15,918,404 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi to all, can someone share an example to how lock/unlock/check if a file is locked inside Google Drive ?

I saw the example in Python but I'm not able to create a correct routine to do it in

That's the examples in Python:

Can someone Help me ?

What I have tried:

This is my routine
If FileID <> "" Then
    Dim file As Google.Apis.Drive.v3.Data.File = Service.Files.Get(FileID).Execute
    Dim metadata = New Google.Apis.Drive.v3.Data.File()
    metadata.Description = "Test01"
    metadata.ContentRestrictions = ' I want to set to read only
    Service.Files.Update(metadata, FileID).Execute()
End If
Updated 31-Mar-22 3:15am

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900