C
cj2
pages = 1
pages.tostring gives me "1"
pages+1.tostring gives me "2.0"
Why did it add the ".0" on there? I was looking for "2" and this screws
me up.
Actually this is what I was doing. In the end what I want is to print a
two digit number with leading 0s.
dim collLetterName as string
collLetterName = "i:\collections\" & Format(Now, "yyyy_MMdd") & "\" & _
thisCustno & "_" & Format(Now, "yyyyMMdd") & "_" & _
pages + 1.ToString.PadLeft(2, "0") & ".pdf"
It should produce "i:\collections\2008_0909\2013420470_20080909_02.pdf"
Instead I get "i:\collections\2008_0909\2013420470_20080909_2.pdf"
How is the best way to format my number for this use?
pages.tostring gives me "1"
pages+1.tostring gives me "2.0"
Why did it add the ".0" on there? I was looking for "2" and this screws
me up.
Actually this is what I was doing. In the end what I want is to print a
two digit number with leading 0s.
dim collLetterName as string
collLetterName = "i:\collections\" & Format(Now, "yyyy_MMdd") & "\" & _
thisCustno & "_" & Format(Now, "yyyyMMdd") & "_" & _
pages + 1.ToString.PadLeft(2, "0") & ".pdf"
It should produce "i:\collections\2008_0909\2013420470_20080909_02.pdf"
Instead I get "i:\collections\2008_0909\2013420470_20080909_2.pdf"
How is the best way to format my number for this use?