Complete String Manipulation

Submitted on: 1/4/2015 3:09:00 AM
By: Dennis M. Santiago (from psc cd)  
Level: Beginner
User Rating: By 9 Users
Compatibility: VB.NET, C++.NET
Views: 1640
     It's a part of my program title complete functions that include all functions, financial, file i/o, math etc., This Tutorial help you a lot to format convert string..,

				Complete String Manipulation 
Asc(), AscW(), Chr(), ChrW(), Filter(),
InStr(), InStrRev(), Join(), LCase(),
Left(), Len(), LTrim(), Mid(), Mid, 
Replace(), Right(), RTrim(), Space(),
Split(), StrComp(), StrConv(), StrDup(), StrReverse(), Trim(), UCase()
Asc(character), AscW(string)
The Asc() function returns the character
code corresponding to the character argument
The AscW() function returns the Unicode character 
code except on platforms that do not support
ex. Output = Asc(W)(MysingleString) MysingleString = w output =119
Chr(Value as Integer)
The Chr() function is the inverse of the Asc() function and returns the character associated 
with the specified character code. Use this function to print characters that donít appear 
on the keyboard (such as line feeds or special symbols).
The ChrW() function returns a string containing the Unicode character except on platforms that donít support Unicode, in which case, the behavior is identical to that of the Chr() function.
ex. Output = Chr(W)(MySingleString) MysingleString = 119 output =w
Filter(inputStrings, value[, include][, compare])
This function returns an array containing part of a string array
Dim intRecCnt As Integer
Dim intCntr As Integer
Dim selNames() As String
Dim Names() As String _ = "Dennis", "Manjon", "Santiago"}
 'Create the Filtered array from the Full array
selNames = Filter(Names, MyInputString)
 'Determine the number of elements in the array
intRecCnt = UBound(selNames)
 'Add Elements to ListBox for each element
 'in the array
For intCntr = 0 To intRecCnt
Next intCntr
MyInputString ="Dennis" 
the Output get the Location = 1
InStr([startPos,] string1, string2[, compare])
InStrRev(string1, string2[, start][, compare]) #
InStr(InputString1, _ InputString2,CompareMethod.Text)
I choice CompareMethod.Text, if the the Input string is equal then it return 1 else 0 
Join(list[, delimiter])
Dim ArrayList() As String = {"Dennis", "Santiago"}
txtOutPut.Text = "The output is : " & Join(ArrayList, MyJoinString)
MyJoinString " Manjon " Output Dennis manjon Santiago
LCase(String) convert to lowercase
ex. lCase(D) output = d
Left(string, Length)
Output = Left("Dennis",2) = "De"
 Output =6
LTrim(string) LTrim() RemoveSpace from left until not found Character
 output = L Trim(" Dennis ")
Result= "Dennis "
Mid(string, start, [length])
Str = Mid("Dennis",2 ,"3")
Output = enn
Replace(expression, find, replacewith[, start][, count][, compare])
Replace("Dennis Santiago", "Dennis", "Den")
Output = Den Santiago
Output = Right("Dennis",3)
output =nis
RTrim(string) Remove space from the rightside
Output = Rtrim("Dennis")
make 3 space
Split(expression[, delimiter][, count][, compare])
 This function is the counterpart of the Join() function. It returns a one-dimensional array containing a number of substrings.
Split("Dennis Santiago","Den" , 2)
Output = Nis Santiago
StrComp(string1, string2[, compare])
Ė1 string1 is less than string2.
 0 string1 is equal to string2.
 1 string1 is greater than string2.
StrComp("Dennis", "Santiago")
output = -1
StrConv(string, conversion)
enter a Number on Conversion 1 to 9 For String Format
StrConv("Dennis", 1)
Output = DENNIS
StrDup(number, character)
This function returns a string of number 
characters, all of which are character
StrDup(3, "d")
Output = DDD
output = StrReverse("Dennis")
Output =sinneD
Remove all Space on String both left and right
Output = Trim(" Dennis ")
output = "Dennis"
Convert to uppercase
Output =UCase("Dennis")
Output = DENNIS
By: Dennis M. Santiago :Email Add don't forget to VOTE for me |-:) Thanks

Other 2 submission(s) by this author


Report Bad Submission
Use this form to tell us if this entry should be deleted (i.e contains no code, is a virus, etc.).
This submission should be removed because:

Your Vote

What do you think of this article (in the Beginner category)?
(The article with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor (See voting log ...)

Other User Comments

 There are no comments on this submission.

Add Your Feedback
Your feedback will be posted below and an email sent to the author. Please remember that the author was kind enough to share this with you, so any criticisms must be stated politely, or they will be deleted. (For feedback not related to this particular article, please click here instead.)

To post feedback, first please login.