I have a C# while loop, does a continue in this loop issue the same behaviour as moving to the next item in the loop? Exactly the same as for a “for loop”.
For example see any problems in the following code sample?
while ((line = file.ReadLine()) != null)
{
string messageDownloadID = line ;
if (String.IsNullOrEmpty(messageDownloadID))
{
continue;
}
}
Thanks in advance.
Yes,
continuemoves to the next iteration of the loop.