Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Removing default values from Parameter when placing report on desktop

Status
Not open for further replies.

Ina

Programmer
Feb 7, 2000
41
0
0
US
Does anyone know of a way to remove &quot;default values&quot; from the drop down list of a parameter when putting the report out on the desktop?<br><br>e.g. I have a prompt that says &quot;Location&quot; and it has states (not a database field) as the default value.&nbsp;&nbsp;Without the row level security of Infoview or hard coding, I can't control the users from selecting a location they should not have access to.<br><br>The only other thing I can think of is leaving one site in the report, refreshing on the desktop and repeating for all sites.&nbsp;&nbsp;That is also a maintenance nightmare.&nbsp;&nbsp;There's got to be a better way.&nbsp;&nbsp;Anyone have any suggestions?&nbsp;&nbsp;thanks.
 
I just tested this with one of my reports.&nbsp;&nbsp;I edited my parameter field and in the default values section I deselected the sql table and removed all default values by pressing the double arrows at the bottom of the screen. <p>LindaC<br><a href=mailto:lcastner@co.orange.ny.us>lcastner@co.orange.ny.us</a><br><a href= > </a><br>
 
It sounds like you want a drop down list of States that correspond to a user's access rights.&nbsp;&nbsp;While the dynamic drop down list is not possible, one way to do this (although not terribly secure) would be to get the UserName as a parameter (possibly a password as well), and pass these to a look up table, which would have a corresponding UserGroup for that user.&nbsp;&nbsp;Link that to another lookup table which has a text field UserGroupStates with all the State abreviations available for that user group.&nbsp;&nbsp;Then add to your WHERE clause <br>{?UserName} = {LookUpName.UserName} AND<br>{LookUpName.UserGroup = {LookUpGroup.UserGroup}<br>{Table.State} IN {LookUp.UserGroupStates}<br>Of course, you would have to maintain these lookup tables (which you are going to need to do anyway to restrict access), and the user (if they had a copy of Crystal Reports) could modify the selection formula to see all states.&nbsp;&nbsp;Definitely not hack proof, but would prevent casual users from seeing data from states they weren't allowed to see. <p>Malcolm Wynden<br><a href=mailto:wynden@island.dot.net>wynden@island.dot.net</a><br><a href= > </a><br>
 
Thanks for the suggestion Malcolm.&nbsp;&nbsp;I won't be able to maintain a table at this time, there's just too many users to keep track of,&nbsp;&nbsp;do you have any other solutions?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top