I want to generate excel with enabling auto-filter option.For that I have create one template excel file by enabling auto-filter option but when I write something into that template excel file auto-filter option disabled again.
Is there any solution to create excel file by enabling auto-filter option.
Not sure if this is what you are looking for (and you don't really describe how you write the file today). "create excel file by enabling auto-filter option" doesn't really make sense to me.
There is the Apache POI that I have used for generating excel files and it works pretty well. Is that was you are using to write excel files today?
I'd have a look at Andy Khan's JExcel. I think it's the best library out there for working with Excel in Java.