The issue is fixed.
I had wrriten DeviceInclude parameter and created a html template.
This html automatically creates a head tag and a body tag with Onload functionality.
This body overrides the system created body tag which contains the code to put the focus on focus field.
as there can be only one body tag..
So i instead of creating a device include for all templates ,I had to write the code in all the screen templates.
The same issue is explained in the below thread.
Regards
Suman