Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Impose Security levels
Message
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Impose Security levels
Miscellaneous
Thread ID:
00711131
Message ID:
00711131
Views:
47
Hi,

In my program, I want to make certain functions accessible to certain users based on their security level.

I have taken care of defining this as a table. Now when it comes to the form, how do I implement this?

What I am trying to do is have one program that looks like this and call it in the INIT event of each form.

<<

Parameters pfname, pbtnname

if parameters()<1 or parameters()<2
return
endif

&pfname.&pbtnname.visible = .F.


>>


But FoxPro translates the line
&pfname.&pbtnname.visible = .F.
as
FormAControlAVisible = .F., for FormA & ControlA

I also tried to use Evaluate as:

lform = pfname + "." + pbtnname + ".visible = .F."
Evaluate(lform)

Am I making this very complicated? How can I accomplish this? Do I have to code this in the INIT event of each form?

Thank you.

Ria
Next
Reply
Map
View

Click here to load this message in the networking platform