 |
| Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0 |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the Classic ASP 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
|
|
|
|

November 10th, 2003, 12:40 AM
|
|
Registered User
|
|
Join Date: Nov 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Server.Transfer Error in ASP 3.0
Hi,
In My Page1.asp Iam using
url = "page2.asp?Id=4364"
Server.Transfer(URL)
When i run the page1.asp Iam getting this error.
Server object error 'ASP 0235 : 80004005'
Server.Transfer Error
/page1.asp, line 10
Invalid URL form or fully-qualified absolute URL was used. Use relative URLs.
Can anyone tell me if querystring can be passed with server.transfer
in asp3.0??How can it be done?
Regards,
M.Bala
M.Balasubramanian
System Officer,
Mumbai.
|
|

November 10th, 2003, 01:45 AM
|
|
Authorized User
|
|
Join Date: Sep 2003
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
QueryString can not be passed for Server.Transfer method. You can give just the path or the .asp file name only.
Balakumar V.
|
|

November 10th, 2003, 01:50 AM
|
|
Friend of Wrox
|
|
Join Date: Jun 2003
Posts: 596
Thanks: 1
Thanked 3 Times in 3 Posts
|
|
I don't use server.transfer so I may be wrong but I believe that all declared and assigned variable are available on the page being transfered to, so if you declare a variable called Id and assign it the value 4364 before the transfer you should be able to use that on the new page without passing it in the querystring.
Can anyone confirm or deny this as I'm really not sure.
======================================
They say, best men are moulded out of faults,
And, for the most, become much more the better
For being a little bad.
======================================
|
|

November 10th, 2003, 01:56 AM
|
|
Authorized User
|
|
Join Date: Sep 2003
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Yes.
Server.Transfer will maintain all of the information that you have in your calling page in the Transferred page.
session variables, application variables and objects as well.
Balakumar V.
|
|

November 10th, 2003, 02:07 AM
|
|
Registered User
|
|
Join Date: Nov 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Quote:
quote:Originally posted by Bala_M
Hi,
Thanks for your immt response.
How to get the values of variables declared in the Page1 in Page2
I have tried this
dim Id
Id="4364"
url = "page2.asp"
Server.Transfer(URL)
In Page 2 i tried to print the value of Id.
But Iam not getting the value.?
How can I do this?
Regards,
M.Bala
|
M.Balasubramanian
System Officer,
Mumbai.
|
|

November 10th, 2003, 03:03 AM
|
|
Authorized User
|
|
Join Date: Sep 2003
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Only Session Variables and Objects, Application Variables and Objects, all of the current contents for the request collections will be available to the .asp file receiving the transfer.
NOT the local variables.
Balakumar V.
|
|

November 10th, 2003, 04:17 AM
|
|
Registered User
|
|
Join Date: Nov 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hi Mr.Balakumar ,
Thank you very much for your prompt reply.
I got your point.
Regards,
M.Bala
M.Balasubramanian
System Officer,
Mumbai.
|
|
 |