Complex report requirement

idiotidiot Member Posts: 651
My client has a rather complex requirement which I'm not sure if it's achievable in Navision...
A temp staff is to access the Aged Receivables report, which is shared by everyone else in the company.
The report will only print records where salesperson = S1 OR country code = C1 from the Customer Card for this particular user.

1. Is this possible to achieve with the standard report? Possible to print the report directly without use of something else calling this report like Report.RUN? How to set filter for this case?

2. Is it possible to control the reports filter or even the Customer tab such that for this user only Print & Preview buttons are shown? Possible to print the report directly without use of something else calling this report like Report.RUN? The purpose is to block the ability for selection in order to restrict the list of customers from being shown.
NAV - Norton Anti Virus

ERP Consultant (not just Navision) & Navision challenger

Comments

  • KarenhKarenh Member Posts: 209
    1. It requires writing code within the report, since the condition is for two different fields. This could be done by modifying the standard report.

    In the Customer OnAfterGetRecord trigger of the report, the code would be something like:
    IF NOT (("salesperson code" = 'S1') OR ("country code" = 'C1')) then
    currreport.skip
    ELSE BEGIN
    { the existing code in the trigger}
    END;


    2. Yes. Edit the properties of the Customer dataitem, removing the ReqFilterFields, and selecting a key in the DataItemTableView property.
  • idiotidiot Member Posts: 651
    Thanks for the reply.
    1. So I guess that means setfilter is not possible...

    2. This report is used by normal users as well so they must be able to select their own filters, so setting a key to remove the tab will not be possible...
    NAV - Norton Anti Virus

    ERP Consultant (not just Navision) & Navision challenger
  • hs_mannhs_mann Member Posts: 17
    Hi

    If your client is using SQL Server option then you can achieve this by using Security Filters on Roles But you have to create a new role for that particular user with specified security filters specified on Role.

    Also in the report call SETPERMISSIONFILTER to apply Role Filters

    Harjot
  • idiotidiot Member Posts: 651
    I got the impression that the Security Filters work with AND such that the specified conditions must be met.
    Does it work with OR?
    NAV - Norton Anti Virus

    ERP Consultant (not just Navision) & Navision challenger
  • hs_mannhs_mann Member Posts: 17
    Hi

    Sorry My Mistake. Security Permissions only Handles AND

    Harjot
Sign In or Register to comment.