473,503 Members | 338 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Methods missed

Hi,

I'm implementing a IHttpModule.

I get the Context object like this:

HttpContext m_HttpContext = (HttpContext)((HttpApplication)
sender).Context);

this is done on the BeginRequest event of the Custom
module when I try to access the following statemen:

m_HttpContext.Request.Path.EndsWith("Login.aspx");

I did not receive any error at the compile or run time but
if I debug and watch this sentence I see this text into
the value field of the watcher.

error: 'm_HttpContext.Request.Path.EndsWith' does not exist

Looks that the EndsWith method is not recongnized for the
Path string object contained into the Request object.

Does any know what is going on?

Regards...
Jul 21 '05 #1
2 1241
What about all the other properties, do they contain the expected values?
Does Path contains something? How about Request? What I am getting at is
that you should make sure that the error is actually applying to the
EndsWith, and not something that came before it.

"Erick" <er************@ge.com> wrote in message
news:26*****************************@phx.gbl...
Hi,

I'm implementing a IHttpModule.

I get the Context object like this:

HttpContext m_HttpContext = (HttpContext)((HttpApplication)
sender).Context);

this is done on the BeginRequest event of the Custom
module when I try to access the following statemen:

m_HttpContext.Request.Path.EndsWith("Login.aspx");

I did not receive any error at the compile or run time but
if I debug and watch this sentence I see this text into
the value field of the watcher.

error: 'm_HttpContext.Request.Path.EndsWith' does not exist

Looks that the EndsWith method is not recongnized for the
Path string object contained into the Request object.

Does any know what is going on?

Regards...

Jul 21 '05 #2
Thanks Peter for you response.

As you know the Path property of the Request object is a
String object which has the the defined methos (i.e.
EndWith(), GetTyep(), Clone(), CompareTo(), ToString()) to
work with the string object but none of this methods works.

The Path property has a value like /app/file.aspx

I already tryed to set it to a string like

string vValue = m_HttpContext.Request.Path;

vValue.EndsWith("file.aspx") but again i see the message
into the watcher the same error: 'vValue.EndsWith' does
not exist

Thanks..

-----Original Message-----
What about all the other properties, do they contain the expected values?Does Path contains something? How about Request? What I am getting at isthat you should make sure that the error is actually applying to theEndsWith, and not something that came before it.

"Erick" <er************@ge.com> wrote in message
news:26*****************************@phx.gbl...
Hi,

I'm implementing a IHttpModule.

I get the Context object like this:

HttpContext m_HttpContext = (HttpContext) ((HttpApplication) sender).Context);

this is done on the BeginRequest event of the Custom
module when I try to access the following statemen:

m_HttpContext.Request.Path.EndsWith("Login.aspx");

I did not receive any error at the compile or run time but if I debug and watch this sentence I see this text into
the value field of the watcher.

error: 'm_HttpContext.Request.Path.EndsWith' does not exist
Looks that the EndsWith method is not recongnized for the Path string object contained into the Request object.

Does any know what is going on?

Regards...

.

Jul 21 '05 #3

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

Similar topics

99
5818
by: David MacQuigg | last post by:
I'm not getting any feedback on the most important benefit in my proposed "Ideas for Python 3" thread - the unification of methods and functions. Perhaps it was buried among too many other less...
0
2328
by: Anthony Baxter | last post by:
To go along with the 2.4a3 release, here's an updated version of the decorator PEP. It describes the state of decorators as they are in 2.4a3. PEP: 318 Title: Decorators for Functions and...
8
2406
by: Matthew Bell | last post by:
Hi, I've got a question about whether there are any issues with directly calling attributes and/or methods of a threaded class instance. I wonder if someone could give me some advice on this. ...
2
2075
by: Craig Ringer | last post by:
Hi folks I've been doing some looking around, but have been unable to find out how to implement class methods on Python objects written in C. "Why are you using C?" you ask? Yeah, so do I....
5
2038
by: Nobody | last post by:
I am trying to write a BTree class, just wondering if I missed any useful methods. This is my class definition so far (excuse the MFC portions, its a project requirement): template <class TYPE,...
9
1353
by: Mike Meyer | last post by:
Another thread pointed out a couple of methods that would be nice to have on Python collections: find and inject. These are taken from <URL:...
175
8641
by: Ken Brady | last post by:
I'm on a team building some class libraries to be used by many other projects. Some members of our team insist that "All public methods should be virtual" just in case "anything needs to be...
19
24564
by: Mike Ruane-Torr | last post by:
Why can't I have a static abstract method in C#? My intention is to have a class-level method that returns a string to supply information about inherited classes, and it is natural to make this...
9
1822
by: Steve Folly | last post by:
Hi, I had cause to change a base class virtual method's signature from const to non-const and realised the compiler didn't warn me about derived classes that hadn't changed: class Base {...
2
1970
by: Tom P. | last post by:
I have a class that ahs several methods. It pulls from a queue so it has to be singleton at that point. The question I have is: does the lock{} statement work across methods? If I have A(), B(),...
0
7203
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
7087
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
7281
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
7334
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...
0
7462
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5579
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3156
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1514
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 ...
1
737
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.