संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
अनुमति
यह एक सूची है, जिसमें उन उपयोगकर्ताओं को दी गई अनुमतियों के बारे में जानकारी होती है जो किसी फ़ाइल या फ़ोल्डर को ऐक्सेस कर सकते हैं. इसमें, उन उपयोगकर्ताओं के बारे में जानकारी नहीं होती जिन्हें साफ़ तौर पर ऐक्सेस दिया गया है. इन प्रॉपर्टी को DriveApp.Permission से ऐक्सेस किया जा सकता है.
किसी एनम को कॉल करने के लिए, उसकी पैरंट क्लास, नाम, और प्रॉपर्टी को कॉल किया जाता है. उदाहरण के लिए,
DriveApp.Permission.VIEW.
// Creates a folder that anyone on the Internet can read from and write to.// (Domain administrators can prohibit this setting for Google Workspace users.)constfolder=DriveApp.createFolder('Shared Folder');folder.setSharing(DriveApp.Access.ANYONE,DriveApp.Permission.EDIT);
प्रॉपर्टी
प्रॉपर्टी
टाइप
ब्यौरा
VIEW
Enum
जिन उपयोगकर्ताओं के पास फ़ाइल या फ़ोल्डर का ऐक्सेस है वे उसे सिर्फ़ देख सकते हैं या कॉपी कर सकते हैं. अगर फ़ाइल का टाइप इस वैल्यू के साथ काम नहीं करता है, तो File.setSharing(accessType, permissionType) को यह वैल्यू पास करने पर अपवाद दिखता है.
ऐसे उपयोगकर्ता जो शेयर की गई ड्राइव में फ़ाइलों और फ़ोल्डर को व्यवस्थित कर सकते हैं. यह वैल्यू दिखाई जा सकती है, लेकिन इसे File.setSharing(accessType, permissionType) में डालने पर अपवाद दिखता है.
FILE_ORGANIZER
Enum
ऐसे उपयोगकर्ता जो शेयर की गई ड्राइव में मौजूद कॉन्टेंट में बदलाव कर सकते हैं, उसे ट्रैश में डाल सकते हैं, और उसे एक से दूसरी जगह मूव कर सकते हैं. इस वैल्यू को दिखाया जा सकता है,
लेकिन इसे File.setSharing(accessType, permissionType) में पास करने पर अपवाद दिखता है.
NONE
Enum
उपयोगकर्ता के पास फ़ाइल या फ़ोल्डर के लिए कोई अनुमति नहीं है. यह वैल्यू लौटाई जा सकती है, लेकिन File.setSharing(accessType, permissionType) में इसे तब तक पास नहीं किया जा सकता, जब तक इसे Access.ANYONE के साथ सेट नहीं किया जाता.
[[["समझने में आसान है","easyToUnderstand","thumb-up"],["मेरी समस्या हल हो गई","solvedMyProblem","thumb-up"],["अन्य","otherUp","thumb-up"]],[["वह जानकारी मौजूद नहीं है जो मुझे चाहिए","missingTheInformationINeed","thumb-down"],["बहुत मुश्किल है / बहुत सारे चरण हैं","tooComplicatedTooManySteps","thumb-down"],["पुराना","outOfDate","thumb-down"],["अनुवाद से जुड़ी समस्या","translationIssue","thumb-down"],["सैंपल / कोड से जुड़ी समस्या","samplesCodeIssue","thumb-down"],["अन्य","otherDown","thumb-down"]],["आखिरी बार 2025-07-26 (UTC) को अपडेट किया गया."],[[["\u003cp\u003e\u003ccode\u003eDriveApp.Permission\u003c/code\u003e is an enum that represents the permissions granted to users for accessing files or folders, in addition to individually assigned permissions.\u003c/p\u003e\n"],["\u003cp\u003eYou can use \u003ccode\u003eDriveApp.Permission\u003c/code\u003e properties like \u003ccode\u003eVIEW\u003c/code\u003e, \u003ccode\u003eEDIT\u003c/code\u003e, \u003ccode\u003eCOMMENT\u003c/code\u003e, etc. to define access levels when setting sharing settings for files or folders.\u003c/p\u003e\n"],["\u003cp\u003eCalling an enum property involves using the parent class, name, and property, such as \u003ccode\u003eDriveApp.Permission.VIEW\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eWhile some properties like \u003ccode\u003eOWNER\u003c/code\u003e, \u003ccode\u003eORGANIZER\u003c/code\u003e, \u003ccode\u003eFILE_ORGANIZER\u003c/code\u003e, and \u003ccode\u003eNONE\u003c/code\u003e can be returned, they cannot be used to set sharing permissions and will throw an exception.\u003c/p\u003e\n"]]],["The `Permission` enum in DriveApp defines user access levels for files/folders. Key permissions include `VIEW` (view/copy), `EDIT` (edit, potentially share), and `COMMENT` (view, copy, comment). `OWNER`, `ORGANIZER`, and `FILE_ORGANIZER` are for ownership and shared drive organization. `NONE` indicates no permissions. `setSharing()` can define these permissions using `DriveApp.Permission.ENUM_NAME`, except for `OWNER`, `ORGANIZER`, `FILE_ORGANIZER`, and sometimes `NONE`. The `setSharing` method also accepts an `Access` type to define who these permissions apply to.\n"],null,[]]