MBSubstr3 Function | |
Extract a substring from a string, using strong typing and three required arguments — both the substring and the string can contain double-byte characters.
Namespace:
XSharp.VO
Assembly:
XSharp.VO (in XSharp.VO.dll) Version: 2.19
Syntax FUNCTION MBSubstr3(
cMBTarget AS STRING,
wStart AS DWORD,
wCount AS DWORD
) AS STRING
public static string MBSubstr3(
string cMBTarget,
uint wStart,
uint wCount
)
Request Example
View SourceParameters
- cMBTarget
- Type: String
The string from which to extract a substring. - wStart
- Type: DWord
The starting position relative to the leftmost character in cMBTarget.
- wCount
- Type: DWord
The number of characters to extract — double-byte characters count as one character.
If wCount is greater than the number of characters from wStart to the end of cMBTarget, the extra is ignored.
Return Value
Type:
String
The substring.
If the substring is not present, or if you specify
wStart as zero, MBSubstr3() returns a NULL_STRING.
Remarks
MBSubstr3() is a typed version of MBSubstr() in which all three arguments are required. Because wStart cannot be negative, MBSubstr3() cannot extract a substring relative to the rightmost character of cMBTarget as can MBSubstr().
Remarks Tip |
---|
This function is the same as Substr3() since .Net has unicode strings |
Examples See Also