473,326 Members | 2,061 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

hyperlinking to a new page

Hi,

I have the following code. Basically, I just want to create a way to show
the detail of the record to a new page. I knew it is relatively simple but
I am a little bit lost. It doesn't seem to send the 'recID' to the new page
hyperlink. What am I missing?

<asp:Repeater id="BookRepeater" runat="server"
OnItemCommand="BookRepeater_ItemCommand">
<ItemTemplate>
<tr>
<td>
<font face="Arial" size="2"> <a
href="http://localhost/showdetails.aspx?recID="&DbReader.Reader('record') .To
String()>
<%#Container.DataItem("Record")%></a>
</font></td>
<td>
<font face="Arial" size="2"><%#Container.DataItem("Author")%>
</font></td>
<td>
<font face="Arial" size="2"><%#Container.DataItem("Title")%>
</font></td>
</tr>
</ItemTemplate>
</asp:repeater>

Thanks,
George
Nov 18 '05 #1
1 1000
You have two options

1.) Replace <a
href="http://localhost/showdetails.aspx?recID="&DbReader.Reader('record') .To
String()>
with
<a href='http://localhost/showdetails.aspx?recID=<%#
Container.DataItem("Record").ToString() %>'>

or
2.) Change the link to a server control and set the href attribute
programmatically.

and all should work as expected

"Gmansky" <gm*****@starmd.net> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
Hi,

I have the following code. Basically, I just want to create a way to show
the detail of the record to a new page. I knew it is relatively simple but I am a little bit lost. It doesn't seem to send the 'recID' to the new page hyperlink. What am I missing?

<asp:Repeater id="BookRepeater" runat="server"
OnItemCommand="BookRepeater_ItemCommand">
<ItemTemplate>
<tr>
<td>
<font face="Arial" size="2"> <a
href="http://localhost/showdetails.aspx?recID="&DbReader.Reader('record') .To String()>
<%#Container.DataItem("Record")%></a>
</font></td>
<td>
<font face="Arial" size="2"><%#Container.DataItem("Author")%>
</font></td>
<td>
<font face="Arial" size="2"><%#Container.DataItem("Title")%>
</font></td>
</tr>
</ItemTemplate>
</asp:repeater>

Thanks,
George

Nov 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Michael Brennan-White | last post by:
If I submit my for using a get action the resulting page loads . If I use a post action I get an error page saying "The page cannot be found". I am calling the originating page!!! This happens...
1
by: Micromanaged | last post by:
I have a customers table in my database (SQL 2k) with a column called . What I would like to set up (if possible) is to have the ASP page, as it returns the requested recordset, if it has an email...
0
by: Nathan | last post by:
Hi, I seem to having a peculiar problem with the display of odd and even pages in XSL-FO. Here is a small background of the problem. My xsl stylesheet mentions my fo:layout-master-set as ...
6
by: Nedu N | last post by:
Hi, I am trying to design a Home page for my applicatiion in which i want show the links for for some itms... I tried to put the following <td> <font face="Arial, Helvetica, sans-serif" ...
2
by: John Lau | last post by:
Hi, Is there documentation that talks about the page lifecycle, the lifecycle of controls on the page, and the rendering of inline code, in a single document? Thanks, John
1
by: Gmansky | last post by:
Hi, I have the following code. Basically, I just want to create a way to show the detail of the record to a new page. I knew it is relatively simple but I am a little bit lost. It doesn't...
1
by: Shisou | last post by:
Hello, So I'm at my wits end with this problem. I'm trying to create an ASP page that will read data from a SQL database. In my production environment I'm using sql 2000 and in my test...
1
by: nicky77 | last post by:
Hi, I've created a nav bar using a background image for rollover effects. Everything works as I had hoped, however, for some reason it seems that an area of whitespace (the same size of the...
1
by: jeffshere | last post by:
I like frames, but wanted to change site from frames to html/css. The problem I am having is in frames I can set the content in a frame by a hyperlink target. In html/css how do I get the content...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.