I am having a problem figuring out if a user is in a role in a VB COM+ application. I have included a reference to "COM+ Services Type Library" (COMSVCS.DLL) and am using the following code:
Function IsAdmin() As Variant
IsAdmin = COMSVCSLib.GetObjectContext.IsCallerInRole("Admins")
The problem is that this function always returns true regardless of whether the caller is in the role or not. Incidentally the GetOriginalCallerName function of the ObjectContext.Security object *is* working.
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.
What are they?
An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…