Babu,
Did you actually read the extensive section written by expert Umesh above, where he describes how to create a MACRO? Have you actually tried any of his detailed instructions?
Did you perform your search of SCN, where there are already hundreds of discussions about this topic; to say nothing of the SCN documents and Wikis that are posted?
Read the SCN rules of engagement:
Especially Item 3 under Etiquette.
and
Search is a Tool: Tips for Better Results
To your question, try these for a start:
Advanced Macros - Planning Area Administration - SAP Library
and then
Best Regards,
DB49