|
Home > Archive > Microsoft Content Management Server > September 2004 > CmsHttpContext in Application events...
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
CmsHttpContext in Application events...
|
|
| Stefano 2004-09-08, 2:48 am |
| Hi all,
I'm trying to write code into "Application_AuthenticateRequest" event
handler into a custom HttpModule
If I access to CmsHttpContext.Current, I have NullReferenceException.
I believe this is normal, because MCMS didn't create its context in that
point.... is it right?
So... What are application events in which I can access to CmsHttpContext?
Thank you so much.
Bye
Stefano
| |
| Stefan [MSFT] 2004-09-08, 7:48 am |
| Hi Stefano,
I have used this context inside the OnPreRequestHandlerExecute event.
Cheers,
Stefan.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
MCMS FAQ:
http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/...t+S
erver
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossne...2/07/41859.aspx
--------------------------------
"Stefano" <stefano__REMOVETHIS__@giasoft.it> wrote in message
news:eXzacAYlEHA.3536@TK2MSFTNGP12.phx.gbl...
> Hi all,
>
> I'm trying to write code into "Application_AuthenticateRequest" event
> handler into a custom HttpModule
> If I access to CmsHttpContext.Current, I have NullReferenceException.
>
> I believe this is normal, because MCMS didn't create its context in that
> point.... is it right?
>
> So... What are application events in which I can access to CmsHttpContext?
>
> Thank you so much.
>
> Bye
>
> Stefano
>
>
| |
| Stefano 2004-09-08, 7:48 am |
| Hi Stefan,
Now I'm using OnPreRequestHandlerExecute event too... and I can access to
Cmshttpcontext.
But... Now I cannot redirect the request to another page. I receive the
following message: Cannot redirect after HTTP headers have been sent.
My code has not sent any http header.
So... how is it possible?
Maybe some MCMS module sends http headers before me?
Thank you so much.
Bye
Stefano
"Stefan [MSFT]" <stefang@online.microsoft.com> ha scritto nel messaggio
news:uyF3T8YlEHA.3156@TK2MSFTNGP12.phx.gbl...
> Hi Stefano,
>
> I have used this context inside the OnPreRequestHandlerExecute event.
>
> Cheers,
> Stefan.
>
> --
> This posting is provided "AS IS" with no warranties, and confers no
rights.
>
> MCMS FAQ:
>
http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm
> MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
> MCMS Sample Code:
>
http://www.gotdotnet.com/community/...t+S
erver
> MCMS Whitepapers and other docs:
> http://blogs.msdn.com/stefan_gossne...2/07/41859.aspx
> --------------------------------
>
>
> "Stefano" <stefano__REMOVETHIS__@giasoft.it> wrote in message
> news:eXzacAYlEHA.3536@TK2MSFTNGP12.phx.gbl...
CmsHttpContext?[vbcol=seagreen]
>
>
| |
|
|
|
|
|
|
| Stefano 2004-09-08, 5:49 pm |
| Now everything is OK !
FFFiuuuu ... Just a coding error ...
Thank you so much.
Bye
Stefano
|
|
|
|
|