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

Using context and server.transfer on a destination page by 2 source pages

I am wondering if I have a single destination page, and 2 or more source
pages, is there a way to tell which type of class is currently in the
context.Handler?

So if i am on the destination page, I can check the context to see whethere
it is page1Source or page2Source, and process differently accordingly. In
order to convert the context.handler, I need to know which source page it
references.

I didn't see any intellisense for a getType for the context.handler. I don't
know if its possible either.

thanks
Jul 19 '05 #1
1 2213
Since ASP.NET pages are classes that extend System.Web.UI.Page, which
implements IHttpHandler, it's available via the Handler property of the
current HttpContext:
Dim myWebPage As Page = HttpContext.Current.Handler

Response.Write(myWebPage.GetType.ToString)

Luke

"Microsoft Security Announcement: Have you installed the patch for
Microsoft Security Bulletin MS03-026?? If not Microsoft strongly advises
you to review the information at the following link regarding Microsoft
Security Bulletin MS03-026
http://www.microsoft.com/security/se...s/ms03-026.asp and/or to
visit Windows Update at http://windowsupdate.microsoft.com to install the
patch. Running the SCAN program from the Windows Update site will help to
insure you are current with all security patches, not just MS03-026."

Jul 19 '05 #2

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

Similar topics

1
by: Mike Husler | last post by:
We tried to load a file that contained 1 column of datetimes of the format yyyy-MM-dd hh:mm:ss into a table that had the column set as a datetime type. We did this using a DTS package. The error...
2
by: Lyn Duong | last post by:
hi all, I am trying to create a dts package to transfer data from tables in my sql server 2000 database to a db2 UDB v8.1.4 database. When I use ibm db2 oledb driver for the destination this...
1
by: trapeze.jsg | last post by:
Hi. I am trying to get through to Microsoft MapPoint Services using ZSI for soap handling. I can generate the service classes and also the soap-requests generated by the service classes seem to...
3
by: yma | last post by:
Hi, I put a .aspx page inside Server.Transfer() within a button. The page was created for testing so it only has button and I did not add code. When I click the button, it gave me an error...
5
by: Julien C. | last post by:
Hi all, I have an "EditeItem.aspx" page which lets me edit properties of an "Item". In the OnClick() event of my Save button, I do save Item changes to the database and then I redirect the user...
11
by: Alexander Bosch | last post by:
Hi, I'm having a problem similar to the one that's stated in this KB http://support.microsoft.com/default.aspx?scid=kb;en-us;839521 When I'm posting a page to itself with the bool value as true it...
3
by: Siobhan | last post by:
I am getting the following error: Run-time exception thrown : System.Web.HttpException - Session state can only be used when enableSessionState is set to true, either in a configuration file or in...
2
by: David Berman | last post by:
It seems that my site is losing session information when using Server.Transfer. I have a page called PictureGallery.aspx. It takes an argument which is an index id, so it would look like...
1
by: | last post by:
I am wondering if I have a single destination page, and 2 or more source pages, is there a way to tell which type of class is currently in the context.Handler? So if i am on the destination...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
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.