document linking

wsyeager

Centurion
Joined
Apr 10, 2003
Messages
140
Location
Weston, FL
I'd like to link to another part of my document within my aspx page.

I have the following code in my HTML:

<code>
<A HREF="#PositionsHeld">Positions Held</A>

<asp:label id="lblPosition" style="Z-INDEX: 107; LEFT: 16px; POSITION: absolute; TOP: 816px"
runat="server" Font-Underline="True" Font-Bold="True" Font-Size="Larger">Positions Held</asp:label>

<H2 id="PositionsHeld"></H2>
</code>

I would like the link to go directly right after the above label. I thought I would be achieving this by using the "<H2 id="PositionsHeld"></H2>" . When I click on the link, it brings me down some on the document, but nowhere near this label.

What am I doing wrong?
 
How about if u put them in a table?

<table>
<tr>
<td> your label code here </td>
<td> you link here </td>
</tr>
<table>

then u wont need that <H2...> stuff. I think. Try it.
 
Get rid of the style attribute wihin the <ASP:LABEL , you are setting an absolute position, which you don't want.
 
Back
Top