|
hi,
i deployed an application to webserver and try to browse it, it gives me this error
" Method not found: System.Collections.Specialized.NameValueCollection
System.Web.HttpRequest.get_ServerVariables() "
I went through some the codes in my .net application and suspected that it was these line that is causing this error,
"strLoginName = RTrim(Request.ServerVariables("LOGON_USER"))
iPos = Len(strLoginName) - InStr(1, strLoginName, "\", 1)
iDom = InStr(1, strLoginName, "\", 1) - 1
strDomain = Left(strLoginName, iDom) 'returns the domain name only
strDomain = strDomain.ToLower() 'change the domain name to lowercase
strLoginName = Right(strLoginName, iPos)"
What i do is trying to retrieve the Windows NT login name from the system, but it prompt out this error.
I have try debug for a few times but i cant find whats wrong with it, does anybody knows whats the solution for this? i really need some help.
P.S: Im using asp.net to build my application
|
|
|
What namespaces are you using? Is the Collections namespace loaded?
|
|
|
|
|
|
|
|
|
|