473,385 Members | 1,907 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,385 software developers and data experts.

Cross page postback

Hi all,

I have been trying to implement cross page postback with a Repeater,
to no avail..

I have a Repeater on search.aspx which lists items from a database. In
each item template is a linkbutton that performs a cross page postback
to details.aspx.

On details.aspx I need to find the item in which the linkbutton was
selected. Is there any way at all to achieve this? Either by passing a
value (like the id of the data item), or by using FindControl to find
a textbox in that item.

I have searched high and low on google and various forums for a whole
day and have found nothing on this. All the examples I've found on
cross page postback reference static controls that are hard coded but
what about data bound items?

Any help would be greatly greatly appreciated.

Cheers,
Karen

Apr 12 '07 #1
2 2015

I see no reason to do a postback at all. use a hyperlink with
display.aspx?id=<itemidand in display.aspx use
Request.QueryString["id"] to get the value. then no javascript is
required, and bookmarks work.

-- bruce (sqlwork.com)


ja*****@mail.com wrote:
Hi all,

I have been trying to implement cross page postback with a Repeater,
to no avail..

I have a Repeater on search.aspx which lists items from a database. In
each item template is a linkbutton that performs a cross page postback
to details.aspx.

On details.aspx I need to find the item in which the linkbutton was
selected. Is there any way at all to achieve this? Either by passing a
value (like the id of the data item), or by using FindControl to find
a textbox in that item.

I have searched high and low on google and various forums for a whole
day and have found nothing on this. All the examples I've found on
cross page postback reference static controls that are hard coded but
what about data bound items?

Any help would be greatly greatly appreciated.

Cheers,
Karen
Apr 13 '07 #2
The reason I need to do a cross page postback is because the target
page needs to know information from the previous page in order to do
things like paging (going to the next and previous result in the paged
data table) and also to remember the search results to navigate back
to.

Can you suggest an alternative way of maintaining this information?
Should I be storing all of this in the session object instead?
On 13 Apr, 16:29, bruce barker <nos...@nospam.comwrote:
I see no reason to do apostbackat all. use a hyperlink with
display.aspx?id=<itemidand in display.aspx use
Request.QueryString["id"] to get the value. then no javascript is
required, and bookmarks work.

-- bruce (sqlwork.com)

jazz...@mail.com wrote:
Hi all,
I have been trying to implementcrosspagepostbackwith a Repeater,
to no avail..
I have a Repeater on search.aspx which lists items from a database. In
each item template is a linkbutton that performs acrosspagepostback
to details.aspx.
On details.aspx I need to find the item in which the linkbutton was
selected. Is there any way at all to achieve this? Either by passing a
value (like the id of the data item), or by using FindControl to find
a textbox in that item.
I have searched high and low on google and various forums for a whole
day and have found nothing on this. All the examples I've found on
crosspagepostbackreference static controls that are hard coded but
what about data bound items?
Any help would be greatly greatly appreciated.
Cheers,
Karen

Apr 16 '07 #3

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

Similar topics

0
by: webserverpete | last post by:
What code do I need to get the value of my Datalist using Cross Page PostBack? Below is my DataList: <asp:DataList ID="DataList1" runat="server" DataSourceID="SqlDataSource1" RepeatColumns="4"...
5
by: Bryan | last post by:
I am trying to get to a label control to get its Text value. from a previous page. The label control is buried in a Web User Control that is in a webpart zone. When I use this code:...
0
by: ibiza | last post by:
Hi all, One of the great new features of ASP.NET 2.0 is cross page postback. I would like to know if it is possible to do a cross page postback from a LinkButton that would launch a new window,...
6
by: bill | last post by:
Is there a way to retrieve values from the viewstate in the previouspage using cross page postback? Thanks! Bill
2
by: Alan Silver | last post by:
Hello, I have just discovered that if you turn off Javascript, then cross-page posting does not work. The postback goes to the originating page, which basically means that nothing happens. I...
1
by: Jason Wilson | last post by:
I have a page that has two seperate buttons that have the same PostbackUrl. How can I tell which button cause the cross-page postback? I posted this before and got the anser sender. ...
0
by: mlg74 | last post by:
I am using cross page postback from default page to default2.aspx. I have set the submit button on default 1 to postback to default2. On default to, on page load, I have typed: PostalCode.Text =...
0
by: jazzart | last post by:
Hi all, I have been trying to implement cross page postback with a Repeater, to no avail.. I have a Repeater on search.aspx which lists items from a database. In each item template is a...
2
by: deshg | last post by:
Hey everyone, I am a php programmer originally and am just helping a friend of mine update their website that they paid a designer (well that's what he called himself!) to do ages ago. I have...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.