Click here to Skip to main content
15,890,897 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
I'm new to VS and .NET framework. I wrote a simple asp.net page that displays a table from a MS access database. My question is how can i make a data in a specific cell as a hyperlink to some page, for example to an html page.

[Edit: Codehawkz]Removed <pre lang="vb"> tag[/code]
Posted
Updated 19-Sep-12 20:55pm
v2

1 solution

Hello

U can use the repeater control for this.
Repeater control allowed the customize code for design.
And just bind the data with control.
 
Share this answer
 
Comments
Sriram Mani 20-Sep-12 2:54am    
Thanks for the reply harshad. if you don mind can you post the code for making a record data in a field as a hyperlink.
this is my code..
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False"
DataSourceID="JOBLISTDS"
onselectedindexchanged="GridView1_SelectedIndexChanged" Width="1000px"
AllowSorting="True" Height="157px" style="margin-top: 0px">
<columns>
<asp:TemplateField HeaderText="JobID" SortExpression="JobID">
<edititemtemplate>

<asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("JobID") %>'>

<itemtemplate>
<asp:Label ID="Label1" runat="server" Text='<%# Bind("JobID") %>'>

<HeaderStyle BackColor="#6699FF" Font-Bold="True" />

<asp:BoundField DataField="JobTitle" HeaderText="JobTitle"
SortExpression="JobTitle">
<HeaderStyle BackColor="#6699FF" Font-Bold="True" />

<asp:BoundField DataField="Organization" HeaderText="Organization"
SortExpression="Organization">
<HeaderStyle BackColor="#6699FF" Font-Bold="True" />

<asp:BoundField DataField="JobLocation" HeaderText="JobLocation"
SortExpression="JobLocation">
<HeaderStyle BackColor="#6699FF" Font-Bold="True" />





in this i want to set a hyperlink for datafield.. for example "JobLocation". the Navigationpage will be another html document
Harshad Kathiriya 20-Sep-12 3:24am    
u want hyperlink on full record or particular columns ?
Sriram Mani 21-Sep-12 9:58am    
i created hyperlink field instead of databound field using same datasource...

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900