princesszea
Technical User
Hi,
I have a while loop that checks a folder for a file, once the file is moved from the folder for some reason the while loop does not exit as it still thinks the length is still one although there is no file in the folder.
Thanks
I have a while loop that checks a folder for a file, once the file is moved from the folder for some reason the while loop does not exit as it still thinks the length is still one although there is no file in the folder.
Code:
while (files.Length > 0)
{
//some code
}
if (files.Length == 0)
{
//some code
}
Thanks