I need your help in solving a problem i am facing.
I am reading files from a particular folder and storing them into Hashtable(Key is filename and value is file object).
I need to read this Hashtable for a particular file extention. After getting particular file, i need to search associated files of first file in the same Hashtable. I need to store all these files in a list.
This part is working fine, but problem here is as i am reading the Hashtable sequentially, the same process will repeatin for the each associated file also. I tried to remove the associated files from Hashtable once they found but it is throwing
Exception in thread "main" java.util.ConcurrentModificationException at java.util.Hashtable$Enumerator.next(Unknown Source) at HashEx.main(HashEx.java:33)
can anybody give some suggestions so that i can avoid of reading associated files.