FileIOPermissionAttribute.Write Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets write access for the file or directory specified by the string value.
public:
property System::String ^ Write { System::String ^ get(); void set(System::String ^ value); };
public string Write { get; set; }
member this.Write : string with get, set
Public Property Write As String
Property Value
The absolute path of the file or directory for write access.
Examples
The following example sets the Write property to grant Write access to files in the specified directory.
// Set the Write property.
[FileIOPermissionAttribute(SecurityAction::PermitOnly,
Write="C:\\Documents and Settings\\All Users\\Application Data\\Microsoft")]
// Set the Write property.
[FileIOPermissionAttribute(SecurityAction.PermitOnly,
Write = "C:\\Documents and Settings\\All Users\\Application Data\\Microsoft")]
' Set the Read, PathDiscovery, Append, Write, and All properties.
<FileIOPermissionAttribute(SecurityAction.PermitOnly, Read:="C:\"), _
FileIOPermissionAttribute(SecurityAction.PermitOnly, _
PathDiscovery:="C:\Documents and Settings\All Users"), _
FileIOPermissionAttribute(SecurityAction.PermitOnly, _
Append:="C:\Documents and Settings\All Users\Application Data"), _
FileIOPermissionAttribute(SecurityAction.PermitOnly, _
Write:="C:\Documents and Settings\All Users\Application Data\Microsoft"), _
FileIOPermissionAttribute(SecurityAction.PermitOnly, _
All:="C:\Documents and Settings\All Users\Application Data\Microsoft\Network")> _
Public Shared Sub PermitOnlyMethod()
Remarks
This property sets access for a single file or directory. Use additional attributes to specify additional files and directories.
Applies to
GitHub पर हमारे साथ सहयोग करें
इस सामग्री का स्रोत GitHub पर पाया जा सकता है, जहाँ आप समस्याएँ बना और समीक्षा भी कर सकते हैं और अनुरोध खींच सकते हैं. अधिक जानकारी के लिए, हमारे योगदानकर्ता गाइड देखें.