Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

EncoderReplacementFallbackBuffer::Fallback Method (Char, Int32)

 

Prepares the replacement fallback buffer to use the current replacement string.

Namespace:   System.Text
Assembly:  mscorlib (in mscorlib.dll)

public:
virtual bool Fallback(
	wchar_t charUnknown,
	int index
) override

Parameters

charUnknown
Type: System::Char

An input character. This parameter is ignored in this operation unless an exception is thrown.

index
Type: System::Int32

The index position of the character in the input buffer. This parameter is ignored in this operation.

Return Value

Type: System::Boolean

true if the replacement string is not empty; false if the replacement string is empty.

Exception Condition
ArgumentException

This method is called again before the GetNextChar method has read all the characters in the replacement fallback buffer.

The GetBytes and Convert methods call Fallback if they encounter an unknown character in their input. If the return value of Fallback is true, the calling method can invoke the GetNextChar method to obtain each character in the replacement fallback buffer.

.NET Framework
Available since 2.0
Return to top
Show:
© 2017 Microsoft