OnClick Events

Y

Yama

Hi,

I would like to create a left nav dynamically as follow:

<table cellspacing="0" cellpadding="2" width="100%" border="0">
<tr>
<td class="Head">Reports</td>
</tr>
<tr>
<td bgcolor="#ffffff" height="17"><img height="7"
src="../ReportsImages/navlink.gif" width="5">
<a class="Normal" id="Companies" href="Reports.aspx"
runat="server">
Companies</a>
</td>
</tr>
<tr>
<td bgcolor="#ffffff" height="17"><img height="7"
src="../ReportsImages/navlink.gif" width="5">
<a class="Normal" id="Banks" href="Reports.aspx" runat="server">
Banks</a>
</td>
</tr>
</table>

code-Behind I have:
Private Sub Companies_ServerClick(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Companies.ServerClick

strReportName = "Companies"

Me.lblReport.Text = "Companies"

End Sub

Private Sub Banks_ServerClick(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Banks.ServerClick

strReportName = "Banks"

Me.lblReportName.Text = "Banks"

End Sub

But what I would like to accomplish is to do this dynmically. Using a
datalist I do not have the power to call on serverclick event to manipulate
the click action. How can I accomlpish the following?

Yama
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top