I have been working on this for a couple of days and I can't figure out why this code doesn't work, so if anyone has any suggestions I would love to hear them... Thanks!
Code
Error
The page cannot be displayed
There is a problem with the page you are trying to reach and it cannot be displayed.
--------------------------------------------------------------------------------
Please try the following:
Click the Refresh button, or try again later.
Open the pignet home page, and then look for links to the information you want.
HTTP 500.100 - Internal Server Error - ASP error
Internet Information Services
--------------------------------------------------------------------------------
Technical Information (for support personnel)
Error Type:
(0x80005000)
/menu.asp, line 13
Browser Type:
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 4.0)
Page:
GET /menu.asp
Time:
Tuesday, July 15, 2003, 11:13:10 AM
More information:
Microsoft Support
Code
Code:
<%@ Language = VBSCRIPT %>
<% Option Explicit %>
<%
Dim strUserName 'The UserName of the person logged in
Dim adsUser 'WinNT object to get the group lists
Dim GrpList 'The Group List
Dim PermissionType 'The type of permissions (Corporate, Store, or Vendor)
Dim group 'The variable to go through each of the groups that user belongs to
'To get the user and all of the groups he or she belongs to
strUserName=Replace(ucase(Request.ServerVariables("LOGON_USER")) , "\", "/")
Set adsUser = getobject("WinNT://" & strUserName) 'LINE 13
'To concatinate these groups together
For each group in adsUser.groups
GrpList = GrpList & ucase(trim(group.name)) & ";"
next
'Figure out permission types
If (instr(1, GrpList, "CORPORATE USERS")) then
PermissionType = "Corporate"
elseif (instr(1, GrpList, "STORE USERS")) then
PermissionType = "Store"
elseif (instr(1, GrpList, "DOMAIN USERS")) then
PermissionType = "Vendor"
End if
%>
Error
The page cannot be displayed
There is a problem with the page you are trying to reach and it cannot be displayed.
--------------------------------------------------------------------------------
Please try the following:
Click the Refresh button, or try again later.
Open the pignet home page, and then look for links to the information you want.
HTTP 500.100 - Internal Server Error - ASP error
Internet Information Services
--------------------------------------------------------------------------------
Technical Information (for support personnel)
Error Type:
(0x80005000)
/menu.asp, line 13
Browser Type:
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 4.0)
Page:
GET /menu.asp
Time:
Tuesday, July 15, 2003, 11:13:10 AM
More information:
Microsoft Support