Joan Wild: I Need Your Help

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Joan,


After following instructions at http://www.jmwild.com/security02.htm I have
my FE secured and working. Now, what I would like to do is make a copy of
the original FE but change the main forms background image to something
different.

In other words, I want two FE's that use the same workgroup file but they
have different looking form backgrounds. Is this possible?

-Alias
 
Hi Joan,
If your real intent is to have a different background based on what user
logs in, you can have just one frontend and do this in some startup code.

That sounds really cool. Can you show me what the code looks like to do this
if I have two users named Amanda Simmons and Ken Malkovich?

-A
 
Each section of a form has a BackColor property. So you need to set each.

You can check who the current user is by using the CurrentUser() function in
the Open event of your startup form.

Select Case CurrentUser()
Case "Amanda Simmons"
Me.FormHeader.BackColor = -2147483633
Me.FormFooter.BackColor = -2147483633
Me.Detail.BackColor = -2147483633
Case "Ken Malkovich"
Me.FormHeader.BackColor = -2147483644
Me.FormFooter.BackColor = -2147483644
Me.Detail.BackColor = -2147483644
Case Else
etc.
End Select

You could also do this based on group membership instead of CurrentUser.
There is a function in the security FAQ you can use to determine if a user
is a member of a group.

I personally don't think this is a good idea. You should leave user's
preferences for colours and schemes up to them.
 
Hi Joan,

Your code is awesome. I think I can modify it to load some custom
backgrounds I created instead of changing colors. At any rate you are the
best. I've seen your other posts throughout this forum and you can hang with
the best of them. Thanks a million Joan and I hope Microsoft pays you like a
millionaire :-)

-A
 
Thanks for you kind words. Just a clarification though; Microsoft doesn't
pay me (or anyone) here. We volunteer our time to help out others.
 
Back
Top