Top "Httpcontext" questions

HttpContext is a class from .NET Framework which provides information about an HTTP request.

Setting HttpContext.Current.Session in a unit test

I have a web service I am trying to unit test. In the service it pulls several values from the …

c# web-services unit-testing httpcontext
Mock HttpContext.Current in Test Init Method

I'm trying to add unit testing to an ASP.NET MVC application I have built. In my unit tests I …

c# unit-testing mocking httpcontext
How does HttpContext.Current.User.Identity.Name know which usernames exist?

This is not necessarily an issue, I am just curious as to how it works. I have a method: public …

c# asp.net httpcontext
Why is HttpContext.Current null?

I have a value that I use in all the application; I set this in application_start void Application_Start(…

c# asp.net iis httpcontext
HttpContext.Current.Request.Url.Host what it returns?

I'm having a local application which has a path: http://localhost:950/m/pages/Searchresults.aspx?search=knife&filter=kitchen …

c# asp.net http httpcontext
HttpContext.Current.User.Identity.Name is Empty

I have a Silverlight application (using MVC) and when i'm building in visual studio, using Visual Studio Development center, there's …

visual-studio iis httpcontext
How to get working path of a wcf application?

I want to get the working folder of a WCF application. How can I get it? If I try HttpContext.…

wcf path httpcontext
Get current System.Web.UI.Page from HttpContext?

This is actually a two part question. First,does the HttpContext.Current correspond to the current System.UI.Page object? …

c# asp.net httpcontext
HttpContext.Current.User.Identity.Name is always string.Empty

Hi I use a custom MembershipProvider. I want to know the current username during an application scenario, but when I …

asp.net httpcontext custom-membershipprovider iidentity
Read Http Request into Byte array

I'm developing a web page that needs to take an HTTP Post Request and read it into a byte array …

c# asp.net httpcontext system.web