ITextBuffer.IsReadOnly Method (Int32)
Determines whether a text insertion would be prohibited at the specified position due to an IReadOnlyRegion.
Namespace: Microsoft.VisualStudio.Text
Assembly: Microsoft.VisualStudio.Text.Data (in Microsoft.VisualStudio.Text.Data.dll)
Syntax
'Declaration
Function IsReadOnly ( _
position As Integer _
) As Boolean
bool IsReadOnly(
int position
)
bool IsReadOnly(
int position
)
abstract IsReadOnly :
position:int -> bool
function IsReadOnly(
position : int
) : boolean
Parameters
position
Type: Int32The position of the proposed text insertion.
Return Value
Type: Boolean
true if an IReadOnlyRegion would prohibit insertions at this position, otherwise false.
Exceptions
Exception | Condition |
---|---|
InvalidOperationException | TakeThreadOwnership has previously been called, and this call is being made from a different thread. |
ArgumentOutOfRangeException | position is negative or greater than the length of CurrentSnapshot. |
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.