Posts

Showing posts from September, 2010

Append Characters to Left of any String -- Use of PadLeft function

Hello everyone ! I heard the function of padLeft,padright in my college.I thought , what is the need of this function, where we used it.I skip this function and called it "useless". but at the time of programming in VS.Net , i got a issue that is To append zeros at left side of a string say "61" and its should be 10 digit string like that "0000000061" then, I start coding ,try to applying "***for if,,,,while & logic****** Select Case**** ". Result : Partially successful , but code was not feasible,reliable....in short.. fail ! Then, while solving the online practice test ,i got the questions of padleft .I was clueless,and remember my carelessness. I got a clue from that test,also got an idea that i can use this function for appending any character to a string at right side or left side of it. So suppose you have string say "61", and you want make it 10 digits string, with zero's at leftside then use padleft function. st