Item not found in this collection error

8

8020

A03 I have a bit of code that changes user password. Works fine until I use
a different workgroup. Even if I copy and paste the workgroup (that works)
to another folder and join the workkgroup at that new location I get "Item
not found in this collection" error. Any assistance much appreciated.

usrx = Me!Combo8
strOldPassword = ""
strNewPassword = Me!Text14

Dim wrk As DAO.Workspace
Dim usr As DAO.User

Set wrk = DBEngine(0)
Set usr = wrk.Users(usrx)

usr.NewPassword strOldPassword, strNewPassword
 
D

Douglas J. Steele

What line of code raises the error?

If it's the line

Set usr = wrk.Users(usrx)

are you sure that usrx contains a correct name?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top