Wrox Programmer Forums
|
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 17th, 2005, 10:25 PM
Registered User
 
Join Date: May 2005
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks peter,

got this working now and appreciate your help thankyou

is there a way to pass the value to the next page without using a query string as we do not wish this querry string to be visible in the followup url address.???
 
Old June 19th, 2005, 08:51 AM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

Yes, you could use a session value. But then you have to change your approach back to the original way. You'll need to use a postback button (imagebutton). When that image button is clicked and the postback handler runs, you save the image path to a session value and then redirect to the image view page which pulls the image path from the session value. This seems accessive and entails an extra page round trip just to move the image path from the querystring to the session. But that's how you could do it.

-Peter
 
Old November 5th, 2006, 07:50 PM
Registered User
 
Join Date: Nov 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Nawski
The question you were asking for, which the answer is not posted anywhere on the web. Because it is so lack of support I decided to copy and paste this part from my web-blog.

Ok now what is your question again? …You want to use ImageButton and pass the parameter to new page. And Davis suggested you change to HyperLink tag. Well, to me both ways are working just fine but each of them has it own advantage.

Now let cut to the core: Here is the general format for <asp:ImageButton> tag

<SCRIPT Runat="Server">

Sub getNewUrl (Src As Object, Args As ImageClickEventArgs)
    â€˜store value parameter
  Dim strOrderNumber as string = Args.CommandArgument.toString
    â€˜pass the parameter to new asp Page.
    Response.redirect(“nextaspx.aspx?orderId=” & strOrderNum)
End Sub

</SCRIPT>

<asp:ImageButton OnClick="Image_Click" Runat="Server"
  ImageUrl=<img src='<%# Container.DataItem("ImagePath") %>'
  CommandName="getNewUrl"
  CommandArgument='<%# Eval("order_number") %>’
  ImageAlign="AbsMiddle"/>

Happy coding.
Terry







Similar Threads
Thread Thread Starter Forum Replies Last Post
Encrypted URL download link benjamr Beginning PHP 1 October 5th, 2008 07:36 PM
Need Help in LoginStatus and Asp:ImageButton [Mini kamii47 ASP.NET 2.0 Basics 0 September 1st, 2007 04:24 PM
post back of an asp.imagebutton produce error gbianchi ASP.NET 2.0 Professional 6 July 11th, 2007 10:00 AM
How to link my button to a URL? larry Flash (all versions) 1 June 26th, 2007 01:00 AM
Radio buttons - link to URL larry HTML Code Clinic 2 November 20th, 2003 08:02 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.