Read Only Functionality

J

JohnLute

I have a combo box with an AfterUpdate Event:

Private Sub cbProfileID_AfterUpdate()
Dim strNewProfile As String

With Me.cbProfileID

' Capture the profile ID the user has selected or entered.
strNewProfile = .Value & vbNullString

If Len(strNewProfile) = 0 Then
' We've no idea what the user has in mind, so
' leave this alone.
Exit Sub
End If

' Is the user's entry an existing profile ID?
If .ListIndex = -1 Then
' This is not an existing profile ID.
' If we aren't on a new record, undo this entry,
' go to a new record, and re-enter it there.
If Not Me.NewRecord Then
.Undo
Me.Undo
RunCommand acCmdRecordsGoToNew
.Value = strNewProfile
' Me.cbProfileID = strNewProfile
End If
Else
' This is an existing profile ID.
' Undo the entry on this record and
' go to the record that was entered.
.Undo
Me.Undo
Me.Recordset.FindFirst "txtProfileID=""" & strNewProfile & """"
End If

End With

End Sub

This works fine, however, when Read-Only Users log into the database then
this function is "dead" for them.

Is there anything I can do to permit this function for Read-Only Users?

THANKS!
 
J

JohnLute

Hi, Lynn!

The combo box serves as a means of navigation and data entry. Can the code
be modified to permit navigation? Is there another way to navigate records
that you could recommend?
 
J

JohnLute

The database is setup in a multiuser environment. Some users are Read-Only
and some have full access. It looks like I'd need a separate combo box to
navigate...?
 

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

Similar Threads

Windows 7 Sendkeys 1
after update code error 2
Access 2007 "no current record" on split form 1
if duplicate goto record 3
dlookup help 0
Searching Across Two Tables For A Record 3
Suppress MsgBox 7
Delete Record 1

Top