Discussion:
How to invoke one of your own pages
Ryan Heath
2008-01-18 12:43:09 UTC
Permalink
Hi,

Does anyone know how to call your own page *within* a page request?
In a server click event I want to render another page (of my own) into
a string for further processing.

I am about to use WebClient and call my own page, but it really
doesn't feel right, there has to be a better way...

// Ryan

===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Brad Wilson
2008-01-18 17:40:39 UTC
Permalink
Extract the reusable bits and make it a server-based control instead?
Post by Ryan Heath
Hi,
Does anyone know how to call your own page *within* a page request?
In a server click event I want to render another page (of my own) into
a string for further processing.
I am about to use WebClient and call my own page, but it really
doesn't feel right, there has to be a better way...
===================================
This list is hosted by DevelopMentor� http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Ryan Heath
2008-01-18 17:58:21 UTC
Permalink
I think no can do ...

The pages contains masterpages with all their own controls and the like.
I need to be able to render any of these pages.

// Ryan
Post by Brad Wilson
Extract the reusable bits and make it a server-based control instead?
Post by Ryan Heath
Hi,
Does anyone know how to call your own page *within* a page request?
In a server click event I want to render another page (of my own) into
a string for further processing.
I am about to use WebClient and call my own page, but it really
doesn't feel right, there has to be a better way...
===================================
This list is hosted by DevelopMentor(R) http://www.develop.com
View archives and manage your subscription(s) at http://discuss.develop.com
===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Christopher Frazier
2008-01-18 18:07:08 UTC
Permalink
Server.Execute() or Server.Transfer() depending on your needs.

--
-Christopher
| AspInsider
http://bluefenix.net/

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.

-----Original Message-----
From: Discussion of building .NET applications targeted for the Web
[mailto:DOTNET-***@DISCUSS.DEVELOP.COM] On Behalf Of Ryan Heath
Sent: Friday, January 18, 2008 11:58 AM
To: DOTNET-***@DISCUSS.DEVELOP.COM
Subject: Re: [DOTNET-WEB] How to invoke one of your own pages

I think no can do ...

The pages contains masterpages with all their own controls and the like.
I need to be able to render any of these pages.

// Ryan
Post by Brad Wilson
Extract the reusable bits and make it a server-based control instead?
Post by Ryan Heath
Hi,
Does anyone know how to call your own page *within* a page request?
In a server click event I want to render another page (of my own) into
a string for further processing.
I am about to use WebClient and call my own page, but it really
doesn't feel right, there has to be a better way...
===================================
This list is hosted by DevelopMentor(R) http://www.develop.com
View archives and manage your subscription(s) at
http://discuss.develop.com
===================================
This list is hosted by DevelopMentorR http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com

===================================
This list is hosted by DevelopMentor� http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Ryan Heath
2008-01-18 18:24:37 UTC
Permalink
Server.Execute with the TextWriter overload seems to be a good
solution candidate!
I know about Server.Transfer and Server.Execute but I never knew it
had such an overload available, thanks!

// Ryan
Post by Christopher Frazier
Server.Execute() or Server.Transfer() depending on your needs.
--
-Christopher
| AspInsider
http://bluefenix.net/
(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
-----Original Message-----
From: Discussion of building .NET applications targeted for the Web
Sent: Friday, January 18, 2008 11:58 AM
Subject: Re: [DOTNET-WEB] How to invoke one of your own pages
I think no can do ...
The pages contains masterpages with all their own controls and the like.
I need to be able to render any of these pages.
// Ryan
Post by Brad Wilson
Extract the reusable bits and make it a server-based control instead?
Post by Ryan Heath
Hi,
Does anyone know how to call your own page *within* a page request?
In a server click event I want to render another page (of my own) into
a string for further processing.
I am about to use WebClient and call my own page, but it really
doesn't feel right, there has to be a better way...
===================================
This list is hosted by DevelopMentor(R) http://www.develop.com
View archives and manage your subscription(s) at
http://discuss.develop.com
===================================
This list is hosted by DevelopMentorR http://www.develop.com
View archives and manage your subscription(s) at http://discuss.develop.com
===================================
This list is hosted by DevelopMentor(R) http://www.develop.com
View archives and manage your subscription(s) at http://discuss.develop.com
===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Christopher
2008-01-18 19:16:43 UTC
Permalink
XD
--
-Christopher
| AspInsider
http://bluefenix.net
Post by Ryan Heath
Server.Execute with the TextWriter overload seems to be a good
solution candidate!
I know about Server.Transfer and Server.Execute but I never knew it
had such an overload available, thanks!
// Ryan
On Jan 18, 2008 7:07 PM, Christopher Frazier
Post by Christopher Frazier
Server.Execute() or Server.Transfer() depending on your needs.
--
-Christopher
| AspInsider
http://bluefenix.net/
(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.
-----Original Message-----
From: Discussion of building .NET applications targeted for the Web
Sent: Friday, January 18, 2008 11:58 AM
Subject: Re: [DOTNET-WEB] How to invoke one of your own pages
I think no can do ...
The pages contains masterpages with all their own controls and the like.
I need to be able to render any of these pages.
// Ryan
Post by Brad Wilson
Extract the reusable bits and make it a server-based control
instead?
Post by Ryan Heath
Hi,
Does anyone know how to call your own page *within* a page request?
In a server click event I want to render another page (of my own) into
a string for further processing.
I am about to use WebClient and call my own page, but it really
doesn't feel right, there has to be a better way...
===================================
This list is hosted by DevelopMentor(R) http://www.develop.com
View archives and manage your subscription(s) at
http://discuss.develop.com
===================================
This list is hosted by DevelopMentorR http://www.develop.com
View archives and manage your subscription(s) at http://discuss.develop.com
===================================
This list is hosted by DevelopMentor(R) http://www.develop.com
View archives and manage your subscription(s) at http://discuss.develop.com
===================================
This list is hosted by DevelopMentor® http://www.develop.com
View archives and manage your subscription(s) at http://discuss.develop.com
===================================
This list is hosted by DevelopMentor® http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com
Continue reading on narkive:
Loading...