Security Filters in Role/Permissions for Reports

gadzilla1gadzilla1 Member Posts: 316
I've been able to have success using Security Filters in the NAV Permissions area. I've used this for tables only to this point. I tried to apply a Security Filter to the Report 10050 Daily Invoicing Report. I cannot apply a Security Filter to the Report...it only seems that I can do that for tables.

I'd like to make it so that the Salesperson Code filter on Report 10050 is set to the user ID if the user ID belongs to a Salesperson. The filter would be non-editable if the user ID is that of a Salesperson. (basically setting this up so they may only see their own sales data)

Has anyone had to do anything like this before? Any tips are appreciated.

Have a great day. Chris

Comments

  • kinekine Member Posts: 12,562
    To set the security filters, call the SETPERMISSIONFILTER on the record variable.
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • gadzilla1gadzilla1 Member Posts: 316
    Thanks for the reply Kine.

    For my situation I'd like the permission set for an individual user of the report, not the report/record inself. Are you saying that I would have to use SETPERMISSIONFILTER on the report itself?

    I'd like to do everything in the Roles/Permissions area with Security Filters, but if that's not possible with Reports then I'll have to use what's available.

    Thanks - Chris
  • kinekine Member Posts: 12,562
    You need to run this function on the DataItem variable (or any record variable), and it will set active permissions filter for active user on the record. The security filters are applied by default only on Rec variables of forms. In other situations you need to set them by this function...
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
Sign In or Register to comment.