Please Help me in creating a replace function. Problem: Their is a alfanumeric value of any lenght (string) and i want to replace its all characters with 'X' except right four characters
Like : Value : 4111111111111111 Result Should be: XXXXXXXXXXXX1111
I have created a function but got stuck:
public function myfunction(str as string)
str.Replace(str.Substring(0, str.Length - 5), 'X') 'but here i want no of x to be equvals to count of lenght of str - 4
end function
please tell me a better fuction to perform such a operation