Request.ServerVariables from a webservice (asmx)
On my serverside pages (intranet environment),开发者_StackOverflow中文版 I use the following code to find out which user is using the page:
Request.ServerVariables("LOGON_USER")
How do I use that command in a webservice (asmx file)? I can't use the line above as I get a message saying that Request is not declared
.
use HttpContext.Current.Request.ServerVariables
...
精彩评论