Skip to main content
Announcements
Defect acknowledgement with Nprinting Engine May 2022 SR2, please READ HERE
cancel
Showing results for 
Search instead for 
Did you mean: 
ashok1203
Creator II
Creator II

NPrinting Dynamic Filters

Hi Everyone,

I had a fields like Fiscal Month and Fiscal year. The values consists in Fiscal year like FY13,FY14,FY15,FY16.... and Fiscal Months like Jan,Feb,Mar..etc. Here, according to my requirement i want select everytime current year value and current Month value. I tried this year(now()),year(today()), month(now()), month(today()) but it's not working for me. Could you please suggest me some more values to get the current FY year(FY16) and FY Month( Apr).

AAK
6 Replies
JonnyPoole
Former Employee
Former Employee

Ashok,  if you want to filter by value in NPrinting, you can create a new field in the QVW that associates a value like 'today' to a date in the data model that shows dates that will include today's date

For example, in the qlik script:

Today:

load

Date,

  today() as Today,

  Year(Today()) as TodaysYear,

  'F' & right(Year(Today()),2) as TodaysFiscalYear

resident <FactTable>

where Date(Date)=Date(Today());

...this would load date data from a fact table where the date =today. When a user selects a filter from this table in NPrinting, it would filter the dashboard for todays date only

ashok1203
Creator II
Creator II
Author

Hi Jonathan Poole,

Thanks for your reply. This solution I tried before. It's working fine. I had did this associations working good,but my users wants to display the list box values like selected value(Green Colour).

AAK
JonnyPoole
Former Employee
Former Employee

I'm not sure i understand which kinds of users are seeing list boxes from qlikview ..

Are your users using 'NPrinting Designer' or are they using 'On-Demand' or are they just receiving emails from NPrinting ?

perhaps send a screenshot of the place where you want to see the list box values.

ashok1203
Creator II
Creator II
Author

Jonathan, The users just receiving the email from Nprinting. But in that mail according their requirement i had scheduled a entire dashboard. The dashboard consists of reports along with list box and all. So, They are thinking like the filters applying in Nprinting should display in the selected value of list boxes.

AAK
JonnyPoole
Former Employee
Former Employee

Hi think you can do this but not with a list box.

Create a straight table with background colors on the cells to mimic the list box

here is a sample background color expression

=if( GetSelectedCount(Country)>0 and  SubStringCount( concat( distinct Country,','), Country)>0, LightGreen(),
if( SubStringCountconcat( {<Country=p(Country)>} distinct Country,',') , concat( distinct Country)), white(),
lightGray()
))


You can see below there is a list box on the left, and straight table in the middle. you can import the straight table into your NPrinting report to see the green/gray/white selections.


would that help ?


Untitled.png

mangalsk
Creator III
Creator III

hello,

In NPrinting filter you can write ='FY'&right(Year(today()),2) and against it has a check box calculate,just check it