Last post Sep 23, 2008 09:30 AM by ngaisteve1
Sep 22, 2008 10:11 AM|ngaisteve1|LINK
Hi, I got the above error message after I have added option strict. Managed to fix some except these two below. Can someone help?
swriterFile.WriteLine(myproductcode.ToString.PadRight(7, " ")
Option Strict On disallows implicit conversions from 'Integer' to 'Char'
Sep 22, 2008 12:23 PM|DkUltra|LINK
Use your_string = CTYPE( your int,string)
Hope this helps
Sep 22, 2008 11:02 PM|ngaisteve1|LINK
Yeah, I know that way but if I add a padright into it, how do I go about fixing this error?
Sep 23, 2008 09:04 AM|DkUltra|LINK
A person needs to do this in 2 steps convert and then add padding else good luck.
Sep 23, 2008 09:30 AM|ngaisteve1|LINK
Okay, but isn't it already uses tostring to convert it into string?