473,804 Members | 3,469 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Set A Parameter Without Redirecting A Page?

can somebody tell me how to set a parameter of my current URL

without using response.redire ct?

I am trying to set a parameter - ResponseId = 4 inside a while loop. is
this possible?

also, is it possible to replace the value of the ResponseId parameter
to, say "5" in the same way?

thanks!

Dec 28 '06 #1
2 1365
Querystring parameters cannot be reset dynamically as they represent a
read-only collection of items in the url.

Of course, something else you could do would be to have a series of local
variables or protected properties that would initially populate from this
list, then change the variable in postback. This would work nicely if you're
using AJAX because then you wouldn't be posting back the whole page. If
you're not using AJAX, then using a response.redire ct doesn't effect you
much because you'll have a full page postback and might as well do the
redirect to avoid worrying about keeping parameter updates in a viewstate.
--

Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006

"pbd22" <du*****@gmail. comwrote in message
news:11******** **************@ n51g2000cwc.goo glegroups.com.. .
can somebody tell me how to set a parameter of my current URL

without using response.redire ct?

I am trying to set a parameter - ResponseId = 4 inside a while loop. is
this possible?

also, is it possible to replace the value of the ResponseId parameter
to, say "5" in the same way?

thanks!

Dec 28 '06 #2

ok, thanks mark.

i dont think this will work as the updated parameter is created in a
while
loop that outputs many values - this is a count.

what i have done is pass my url querystring through a hidden iframe
from
the referring page (i am uploading files). now, what i want to do is
send a
count back to the referring page (the count represents upload time). i
thought i might be able to do this in the querystring but this would
cause
numerous postbacks in sequence - not pretty.

since it looks like doing it via the querystring is a no-go, do you
have any ideas how
i might send the upload count back to the referring page? is it
possible to send an ajax response from the server when the client does
not initiate the call?

thanks.
peter

Mark Fitzpatrick wrote:
Querystring parameters cannot be reset dynamically as they represent a
read-only collection of items in the url.

Of course, something else you could do would be to have a series of local
variables or protected properties that would initially populate from this
list, then change the variable in postback. This would work nicely if you're
using AJAX because then you wouldn't be posting back the whole page. If
you're not using AJAX, then using a response.redire ct doesn't effect you
much because you'll have a full page postback and might as well do the
redirect to avoid worrying about keeping parameter updates in a viewstate.
--

Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006

"pbd22" <du*****@gmail. comwrote in message
news:11******** **************@ n51g2000cwc.goo glegroups.com.. .
can somebody tell me how to set a parameter of my current URL

without using response.redire ct?

I am trying to set a parameter - ResponseId = 4 inside a while loop. is
this possible?

also, is it possible to replace the value of the ResponseId parameter
to, say "5" in the same way?

thanks!
Dec 28 '06 #3

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

Similar topics

3
2336
by: lozd | last post by:
Would appreciate any solutions people could offer for this. Basically I wan't to use a frameset with an aspx page as the contents rather than a htm page and I'd like to be able to redirect the main page from the code behind the contents page. I want to do this to allow the use of asp "linkbuttons" instead of hyperlinks so I can do a little processing before redirecting. The main reason for this to prevent hyperlinks of pages that have...
6
3064
by: Kamilche | last post by:
I have a large project that is getting complex, and I would like to print the docstrings without importing the modules. The only Python utility I could find references is apparently defunct and hasn't been updated in 4 years. I don't care how spartan the output is - it could look exactly like python's internal docstrings, for all I care. It would be a nice added bonus if it printed to HTML, but not if it greatly increased the interface...
4
1498
by: Greg Smalter | last post by:
Redirecting from page to page within a web project is pretty easy. However, all Redirect methods take strings as arguments, as if you mistype the string, you don't find out until run time that you are redirecting to somewhere that doesn't exist. Worse, if you do type it correctly, but then later the page name changes or the page moves, you still won't find out until run time. I have a framework that solves this problem and guarantees,...
3
284
by: lozd | last post by:
Would appreciate any solutions people could offer for this. Basically I wan't to use a frameset with an aspx page as the contents rather than a htm page and I'd like to be able to redirect the main page from the code behind the contents page. I want to do this to allow the use of asp "linkbuttons" instead of hyperlinks so I can do a little processing before redirecting. The main reason for this to prevent hyperlinks of pages that have...
0
9588
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10340
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10327
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7625
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6857
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5527
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5663
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4302
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2999
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.