Qlik Community

Ask a Question

Qlik NPrinting Discussions

Discussion Board for collaboration on Qlik NPrinting.

Announcements
Welcome to our newly redesigned Qlik Community! Read our blog to learn about all the new updates: READ BLOG and REPORTED ISSUES
cancel
Showing results for 
Search instead for 
Did you mean: 
Contributor II
Contributor II

selection not working in nprinting on demand with linked Field

Created word report with multiple connection with QVW.(connection as  QVW1Connect , QVW2connect)

Created linked field City.(Keep matched value only)

When doing selection in City field in On- Demand APP selection is applied on object of only one APP.

In connection ID Attribute of on-demand added QVW1Connect


but selection is happening on QVW1 only.


Kindly help.

1 Solution

Accepted Solutions
Employee
Employee

  1. Create the linked field to link the city field from two .QVWs
  2. Create the filters you think you need by using the city linked field. For example create the filters: Ottawa, Lund, New York
  3. In the load script of the .QVW that you use as On-Demand User Interface add the load of a field with the name of the created filters. Something similar to

    AdditionalLinkedCityFilters:

    LOAD * INLINE [

    LinkedCityFilterID

    LinkedFieldCityFilterNewYork

    LinkedFieldCityFilterLund

    LinkedFieldCityFilterOttawa

    ];

  4. In the .QVW that you use as On-Demand User Interface add a listbox that shows the LinkedCityFilterID
  5. Add an On-Demand report button configured to run the report you want and in the Filter Setting - Additional saved filter add the formula =GetFieldSelections(LinkedCityFilterID,',') & ''. This read the selection a user do in the listbox previously added
  6. Select a filter and run the report


Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.

View solution in original post

11 Replies
Employee
Employee

Hi,

This is works as design. We are speaking about Qlik NPrinting 16.* because you mention linked fields that are not available in 17.*.

Qlik NPrinting 16.* with On-Demand uses only current selections of the document where you made the selections.

As workaround you can create Qlik NPrinting filters and use them via On-Demand.

Best Regards,

Ruggero

---------------------------------------------

When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
Contributor II
Contributor II

Kindly elaborate you point.

How to do as per your suggestion.

Employee
Employee

  1. Create the linked field to link the city field from two .QVWs
  2. Create the filters you think you need by using the city linked field. For example create the filters: Ottawa, Lund, New York
  3. In the load script of the .QVW that you use as On-Demand User Interface add the load of a field with the name of the created filters. Something similar to

    AdditionalLinkedCityFilters:

    LOAD * INLINE [

    LinkedCityFilterID

    LinkedFieldCityFilterNewYork

    LinkedFieldCityFilterLund

    LinkedFieldCityFilterOttawa

    ];

  4. In the .QVW that you use as On-Demand User Interface add a listbox that shows the LinkedCityFilterID
  5. Add an On-Demand report button configured to run the report you want and in the Filter Setting - Additional saved filter add the formula =GetFieldSelections(LinkedCityFilterID,',') & ''. This read the selection a user do in the listbox previously added
  6. Select a filter and run the report


Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.

View solution in original post

Contributor II
Contributor II

Can you suggest how to handle if City field has 50 values.

Do i need to create 50 filters?

Employee
Employee

Yes, if the City field has 50 values and you must keep the two .QVWs separete you must create 50 filters with the solution I suggested.

Another idea is to create a new .qvw and use it as source for Qlik NPrinting. This qvw reads data from the two other sources and you creates On-Demand report from it so you can use current selections. Another advantade to do this is that the .qvw for NPrinting can be optimized to reduce report creation time.

Best Regards,

Ruggero

---------------------------------------------

When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
Partner
Partner

Hi Ruggero,

Thanks for the explanation. But I still cannot get the linked fields working with OnDemand. Can you give a more detailed explanation at point 4 and 5 in the how to. Which filters do I need to create on the NPrinting Task. How does NPrinting know that =GetFieldSelections(LinkedCityFilterID,',') & ''. connects to that field in Qlikview?

Kindly a more detailed explanation.

Kind regards, Gerald

Employee
Employee

Hi,

You can give a check at the attached example. It contains:

  • an NPrinting project with the linked field and the filters
  • the .qvw Sales Demo for Ajax that is the user interface for On-Demand. The script loads the filter names that are displayed in the list box so you can select the one you want to apply before to run the on demand request
  • the two QVWs used as data source

The example implemented the solution I explained. The template is a very simple Excel example.

=GetFieldSelections(LinkedCityFilterID,',') & '' is inserted in the Filter settings of the On-Demand report button called "Click here for the Linked Fields Example" in the SalesDemo for Ajax.qvw. It retrieves the selected filter name from the list box. Remember to open it in web view.

Let me know if you have more questions.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
Partner
Partner

Hi Ruggero,

Thank you for the information you've shared. If I run the QVW selecting  with Linkedfield = 2011. Then it works fine. If i select another year. Then it doesn't work anymore. Can you check if you can make another yearselectie and the Export  selected properly? I couldn't get it working?, of

Kind regards, Gerald

Employee
Employee

Hi Gerald,

My mistake, sorry, but easy to be resolved:

- open the file C:\NP_Training\NPrintingFiles\OnDemand.nsq

- open the only Excel report

- remove the filter "LinkedFieldYear = 2011" from the report

- save the .nsq file



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.