Question : Padding Emptry spaces with Zero's in VB.NET

Hello,

I 'm having problem padding empty spaces in VB.NET

Dim strPad as string = "         "
Dim strCheck As Int32 = 10
                    Dim pad As Char
                    pad = Convert.ToChar("0")
                 
                    strPad= strPad.PadLeft(strCheck, pad)

still I get Empty spaces in the strPad

Answer : Padding Emptry spaces with Zero's in VB.NET

Dim strPad As String = "         "
        strPad = strPad.Replace(" ", 0)
Me.textbox1.text=strPad
Random Solutions  
 
programming4us programming4us