@sandeep1414,
the earlier replies have given you already a lot of answers.
imho you would get more detailed replies if you would show what you have tried yourself, instead of repeating the same question over and over.
@piyashrija4488 has practically given you the code.
@baszer has told you where to put that code.
@mindblender 3D has given you a link to a very good documentation which explains a lot.
this forum is about giving you helping pointers to information that will enable you to do the final programing yourself, and helping you to learn to find information yourself – it is not about giving you a ‘copy/paste’ solution to modify your theme.
make backup copies before editing theme files
from the information given in the above replies you could have put this code together:
<div id="navigation">
<ul>
<?php wp_list_pages('title_li='); ?>
</ul>
</div>
to be put into header.php, exactly before this line:
<div id="wrapper">
the styles to make it stick to the top, are as follows, and you could add them to style.css:
body {padding-top:30px;}
#navigation {position:fixed; width:100%; margin-top:-30px; background:#999; z-index:1000; }
#navigation ul {height:30px; width:950px; margin:0 auto; display:block; }
#navigation li {display:inline; float:left; margin: 7px 20px 0 0; font-size:130%; }
and you probably want to remove the existing menu:
try and add #mainmenu ul { display:none; }
to style.css, after the existing style of #mainmenu ul {}