Click or drag to resize
StringStartsWith Method (String, Boolean, CultureInfo)
Determines whether the beginning of this string instance matches the specified string when compared using the specified culture.

Namespace: System
Assembly: mscorlib (in mscorlib.dll) Version: 4.0.0.0
Syntax
C#
public bool StartsWith(
	string value,
	bool ignoreCase,
	CultureInfo culture
)

Parameters

value
Type: SystemString
The string to compare.
ignoreCase
Type: SystemBoolean
true to ignore case during the comparison; otherwise, false.
culture
Type: System.GlobalizationCultureInfo
Cultural information that determines how this string and value are compared. If culture is null, the current culture is used.

Return Value

Type: Boolean
true if the value parameter matches the beginning of this string; otherwise, false.
Exceptions
ExceptionCondition
ArgumentNullExceptionvalue is null.
See Also