Remove a file shared with me using Google Drive SDK [duplicate] - google-api

This question already has an answer here:
How to programmatically remove a file from "share with me" in Google drive
(1 answer)
Closed 3 years ago.
When right click a file under the "Shared with me" node on Google Drive a context menu item called "Remove" is available to remove the selected item that is shared with me.
Is there a way to achieve the same using Google Drive SDK? Thanks a lot.

Drive V3 - With shared with me the user has a permissions record for the file. If you remove that then the file will no longer be shared with the user.

Unfortunately the API currently doesn't support this operation. Please file a feature request here: https://code.google.com/a/google.com/p/apps-api-issues/issues/entry?template=Feature%20request&labels=Type-Enhancement,API-Drive

Related

How can I use the drive.file oauth2 scope with a folder in Google Drive? [duplicate]

This question already has an answer here:
Does Google Drive's 'per file' scope cascade into child folders/files?
(1 answer)
Closed 4 years ago.
I'm working on a web app that will work with users' folders in Google Drive rather than individual files. I'd like to request the minimum permissions needed by using the drive.file scope. I'm using the Drive picker UI to allow the user to select a folder, which works nicely with the drive.file and adds the folder to the list of folders my app can access.
However, the problem is that it only grants access to the folder as if it were a single file, without also recursively granting access to all the files and subfolders inside the folder the user selected. My app currently doesn't with the Drive UI to provide an Open with... option for folders, so I don't know if that would grant the correct access permissions or not.
How can I use the Google Drive picker UI to select a folder while using the drive.file scope?
If you're looking for folders using Drive Picker, can you try using the google.picker.​ViewId.FOLDERS view? I've used the Drive Picker in my web app as well and I use google.picker.​ViewId.DOCS_IMAGES view because I'm working on image files. If this does not address your issue, it may not be supported yet.

My Google add-on script is no longer recognizing me as the owner

I don't believe there's any way to contact a human being at Google to help with this, unfortunately.
I have an add-on that I developed years ago: https://chrome.google.com/webstore/detail/doc-variables/ggigadkkljhdchdhpliohdcokbnpcnjn?hl=en
In the last few weeks (last publish 5/29/17) I can no longer publish from the script editor. It says, "Only the owner of a script can publish the script as an add-on.".
I know I own the app/script:dashboard screenshot
One item to mention is that our organization (the account associated with it) recently changed our domain. Is it possible this disconnected my ownership some how? Anyone have any ideas on what I can do?
The screenshot shows that you own the webstore item but not that you own the script itself.
If it's a standalone script, then make sure you also own the script document in Google Drive. Perhaps, the ownership has been changed or you've opened Script Editor with a different account. If the ownership has been changed and you cannot change it back, you can make a copy of the script that you'll own.

Put a shortcut under Windows Quick access list? [duplicate]

This question already has answers here:
Is it possible programmatically add folders to the Windows 10 Quick Access panel in the explorer window?
(10 answers)
Closed 7 years ago.
I need to put a shortcut programmatically under Quick access list, just like DropBox and OneDrive did, see the picture: http://i.imgur.com/l5o2qzH.jpg.
Is there any documentation on how to do this?
You can do this by simply creating a shortcut to specific folder inside C:\Users\YourUserName\Links
This works on Windows 7. I need to test this on Windows 10.
EDIT: This method does not work on Windows 10

send file location to a textbox while user clicks on file then application runs [duplicate]

This question already has an answer here:
Associating file extensions with a program
(1 answer)
Closed 8 years ago.
My application saves a file with *.SAH type (it is a custom file type). Then i can open it with a file open dialog.
Im wondering how i can send the file location to a textbox when user directly clicks on that file. in other words, the user clicks on the file and then my application runs and on form load, my textbox.text will be the path of file .
In the MSDN are good information with examples.
Try editing the registry using RegCreateKey() and RegCloseKey() apis.

mac app main bundle resource permission with sandbox and entitlement [duplicate]

This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
Mac OS X: Where should I store save games for a game delivered as a bundle?
i am migrating my iOS game to mac. The file I used to store high scores is saved under xxx.app/Contents/Resources. However, when I enable the sandbox and entitlement, the directory becomes unwritable. I tried xxx.app and xxx.app/Contents as well without luck.
so which directory should I use or which entitlement should I add?
EDIT
I have tried ~/Library/Application Support/Your Game Name/ and it does not show permission errors but unable to save the game data. there is no Library under user/my_name, but one under unser/shared. Do i need to add any entitlements?
EDIT 2:
Please dont close this question. The answer to earlier question does not work for me. Instead, the flagged answer of this question is correct.
Under app sandboxing your app has a container folder in which it can write pretty much anywhere, however I would recommend just writing to the Data/Documents folder, which can be obtained using the following code:
NSString *documentDir = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) objectAtIndex:0];
This will give you the folder at ~/Library/Containers/com.yourdomain.yourapp/Data/Documents. Note that the ~/Library folder is hidden under Lion/Mountain Lion so needs to be unhidden using this on the command line:
$ chflags nohidden ~/Library
(Only you, the developer, needs to unhide that folder so you can poke around from Finder to see what your app has written; your user's won't need to unhide it to use your app).

Resources