//outwindow is the name of textarea outwindow.setText(outwindow.getText()+ "\n Scanning ..... "+file_name);
Thread.sleep(100);

System.out.println(outwindow.getText());
while(br.readLine()!=null)
{
String name = br.readLine();
// System.out.println(name);
if(file_name.contains(name))// if it is a file then checking its name from
{ // the list
worm_count++;
outwindow.append("\n Worm Detected of the type"+name);
listoffiles[i].delete();
outwindow.append("\n Worm has been deleted");
}
}
}
else if(listoffiles[i].isDirectory()) // this is to check wether its a directory or not
{
dir_count++;