XML Seperate FILES

I Have a file with all the UK postcodes, and a flash file which when you search for a postcode it comes up with the town name, BUT it runs too slow so, so now i need help…

i need to set all the postcodes beggining with “a” into a seperate XML file and so-on with all ther other letters so it wont crash!

so can anyone please tell me how i would do this…
when a user types OL10 for example i want it to run off and find the “O”.xml file and check through it for OL10 and so on for the rest of the alphabet, please help…