Gets a value indicating whether the current stream supports writing.
Assembly: mscorlib (in mscorlib.dll)
The following example uses the CanWrite property to check whether a stream supports writing.
The following is an example using the CanWrite property. The output of this code is "MyFile.txt is writable." To get the output message "MyFile.txt can be both written to and read from.", change the FileAccess parameter to ReadWrite in the FileStream constructor.
Available since 10
Available since 1.1
Available since 2.0
Windows Phone Silverlight
Available since 7.0