CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 Field level security - question to Alex

Print topic Send  topic

Author Message
Tomasz
Posted: 01/22/2002, 4:09 PM

Re. your article in T&T:

Is it possible to leave field as text box and change it to label if user has access rights < 3?

In that case, there would be no need to put custom SQL (I have almost 20 fields to include in that sql...)

btw: you wrote to put first piece of code in "Before Update"; i suppose it have to be "before show"? and the second code in "Before Update"?
Nicole
Posted: 01/23/2002, 4:16 AM

Tomasz,
on the form you should field type to Label and select 'HTML' checkbox on its properties. Then you should create 2 events:
- BeforeShow. Check the user rights and create textbox if need. E.g.:
ASP
if Session("UserRights") = 3 then
fldfield_name = "<input type= ""text"" name = ""field_name"" value = ""& fldfield_name&"">"
end if

- CustomAction event. Here you should check the user rights again and if UserRights = 3 edit insert and update sql queries to include the field into them.
Tomasz
Posted: 01/23/2002, 6:30 AM

Nicole,
Believe me or not, I've read this article;-)
In my question I mean reverse situation:
Is it possible to have text box by default, and change it to label if userrights are lower than 3?

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.