$ 0 0 the main problem with this conversion into VB.NET is that you are calling reader.Read twice in the while loop and ignoring the results of the first. Just do While true, and then if read = 0 break out of the while loop