Re: Why will this code run on server 2000 but not on server2003
- From: "Al Mulnick" <amulnick_No_SPAM@xxxxxxxxxxx>
- Date: Fri, 8 Jul 2005 09:24:19 -0400
Have you checked the event log (the security even log; auditing of failed
login will be needed) to see what account is being presented to the AD when
you run this code? My guess is that you have some permissions issues, but
it's necessary to know if it's local to the IIS machine or not.
You may also want to post this to an IIS newsgroup to see if you get faster
results. There were a LOT of security changes between IIS5 and IIS6.
Your error code just says that there is no table after execution. That's
great, but you'll need to find out why and I would guess it's due to the
security settings or credentials being passed.
Al
"Tom Winslow" <TomWinslow@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:BABEA3FF-966A-47D7-AF13-83093C1A9FB5@xxxxxxxxxxxxxxxx
> This is the error I get:
> Error Type:
> Provider (0x80040E37)
> Table does not exist.
> clsUsers.asp, line 20
>
> Line 20 is Set Rs = command.Execute
>
> "Al Mulnick" wrote:
>
>> Could be that IIS 6 and IIS 5 are quite different. What error are you
>> getting when you execute?
>>
>> "Tom Winslow" <Tom Winslow@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> news:0C5B0ACC-A011-45A8-A487-BE30AA85853F@xxxxxxxxxxxxxxxx
>> > Public Function GetUsers()
>> >
>> > Set oConnect = CreateObject("ADODB.Connection")
>> > oConnect.Provider = "ADsDSOObject"
>> > oConnect.Properties("User ID") = stUser
>> > oConnect.Properties("Password") = stPass
>> > oConnect.Properties("Encrypt Password") = True
>> > oConnect.Open "DS Query", stUser, stPass
>> >
>> > Set command = CreateObject("ADODB.Command")
>> > Set command.ActiveConnection = oConnect
>> > command.CommandText = "SELECT ADsPath, cn, givenname, sn FROM
>> > 'LDAP://OU=Default Users, DC=XXXO1,DC=LOCAL' WHERE objectClass='user'
>> > ORDER
>> > BY cn"
>> >
>> > Set Rs = command.Execute
>> >
>> > While Not Rs.Eof
>> > UserName = rs("cn")
>> > LastName = rs("sn")
>> > FirstName = rs("givenname")
>> > If IsArray(LastName) And IsArray(FirstName) Then
>> > FullName = LastName(0) & ", " & FirstName(0)
>> > Response.Write "<OPTION value='" & UserName(0) & "'>" & FullName &
>> > "</OPTION>"
>> > End If
>> > Rs.MoveNext
>> > Wend
>> >
>> > Set Rs = nothing
>> > oConnect.Close
>> > Set oConnect = nothing
>> >
>> > End Function
>>
>>
>>
.
- References:
- Why will this code run on server 2000 but not on server2003
- From: Tom Winslow
- Re: Why will this code run on server 2000 but not on server2003
- From: Al Mulnick
- Re: Why will this code run on server 2000 but not on server2003
- From: Tom Winslow
- Why will this code run on server 2000 but not on server2003
- Prev by Date: active directory 2003 computer migration problem
- Next by Date: ADAM Install Error
- Previous by thread: Re: Why will this code run on server 2000 but not on server2003
- Next by thread: Active Directory mass import + attributes
- Index(es):
Relevant Pages
|