Hi all,
Using Access 2007 on Windows 7 machine.
Every time I make a call to the following function Access crashes. Does this mean I need to re- register the MS ADO Ext 2.8 for DDL & Security dll on the machine? or is the problem elsewhere?
This seems to run fine on other PCs with the same config, just one PC giving me a problem.
Public Function ReadSecGrp(strUser As String) As String
'Purpose : Get CurrentUser's User Group
Dim cat As New ADOX.Catalog
Dim cnn As ADODB.Connection
Dim grp As ADOX.Group
' Open the catalog
Set cnn = CurrentProject.Connection
cat.ActiveConnection = cnn
For Each grp In cat.Users(strUser).Groups
If grp.Name = "Users" Then
'Skip this group.
Else
ReadSecGrp = grp.Name
End If
Next
End Function
Using Access 2007 on Windows 7 machine.
Every time I make a call to the following function Access crashes. Does this mean I need to re- register the MS ADO Ext 2.8 for DDL & Security dll on the machine? or is the problem elsewhere?
This seems to run fine on other PCs with the same config, just one PC giving me a problem.
Public Function ReadSecGrp(strUser As String) As String
'Purpose : Get CurrentUser's User Group
Dim cat As New ADOX.Catalog
Dim cnn As ADODB.Connection
Dim grp As ADOX.Group
' Open the catalog
Set cnn = CurrentProject.Connection
cat.ActiveConnection = cnn
For Each grp In cat.Users(strUser).Groups
If grp.Name = "Users" Then
'Skip this group.
Else
ReadSecGrp = grp.Name
End If
Next
End Function