Now we will create the structure of the Grid. We will start
with the Header of the Grid.
Note that I have already created a CSS File which you will
find the same in the sample code.
Listing 2
<div id = "dvHeader">
<table id = 'tblHeader' cellpadding = "0" cellspacing = "0" width = '800px'>
<tr class = 'header'>
<td class = "headercell">Customer ID</td>
<td class = "headercell">Company Name</td>
<td class = "headercell">Contact Name</td>
<td class = "headercell">Contact Title</td>
<td class = "headercell">City</td>
</tr>
</table>
</div>
Then we will create the div with runat = "server"
tag which will act as content. The runat = "server" tag will allow
the div to be accessed server side. Since first time when the page loads the
HTML markup will be binded using the innerHTML property of DIV.
Listing 3
<div id = "dvContent" runat ="server" >
</div>
Finally, the third and the last part will act as a Pager for
the Grid.
Listing 4
<div id = "dvPager" runat = "server" style =" text-align:right; width:800px" >
</div>