VB.NET
'''
<summary>
'''
VB6のRight関数を実装する方法
'''
</summary>
'''
<param name="strValue"></param>
'''
<param name="intLen"></param>
'''
<returns></returns>
Public Shared Function
Right(strValue As String, intLen As Integer) As String
If
intLen <= strValue.Length Then
Return
strValue.Substring(strValue.Length - intLen)
End If
Return
strValue
End Function
C#
///
<summary>
///
VB6のRight関数を実装する方法
///
</summary>
///
<param name="strValue"></param>
///
<param name="intLen"></param>
///
<returns></returns>
public static string
Right(string strValue, int intLen)
{
if
(intLen <= strValue.Length)
{
return strValue.Substring(strValue.Length - intLen);
}
return
strValue;
}