기본 콘텐츠로 건너뛰기 보완적인 콘텐츠로 건너뛰기

Using a level to loop over app data

You can loop and repeat the creation of report elements using data from the Qlik Sense app.

For an overview of levels, see Working with levels.

video thumbnail

High-level workflow

This is the recommended workflow for using levels in your PixelPerfect report. It covers some of the most common and simple ways to work with levels in the designer.

Part 1: Add data bindings

First, you need to add the data binding that will be used to cycle the generation of unique report elements. For example, if you want a separate section in the report for each region, you need to add a Region field as a data binding. Data bindings are added in the Database icon with plus symbol Field List menu.

This workflow assumes you already have content, in the applicable areas in the template, for which you want to create a level.

  1. Open the Database icon with plus symbol Field List menu available from the right-side panel in the designer.

  2. Click the plus icon next to Levels.

  3. Expand the sections to find the item you want to use. You can select a field from Fields, or an entire chart from any of the sheet sections.

  4. Click the Plus icon next to an item to add it as a data binding.

Part 2: Connect the data binding to the band

Next, you need to connect the level data binding to a band.

You cannot bind a level to the default Detail1 band, so you will need to create a new DetailReport band for content where you plan on using a level.

  1. Create a new DetailReport band. See Creating a new band.

  2. Select the new band, if not already selected.

  3. Open the Gear Properties menu from the right side of the designer.

  4. Under Detail Report Tasks > Data Member, select the item to use as the level.

Refreshing source data for data bindings

수준 데이터 바인딩으로 추가된 차트에 사용된 소스 앱 데이터를 새로 고칠 수 있습니다. 다음과 같은 경우 유용합니다.

  • 데이터 바인딩을 만든 이후 소스 차트에 차원과 측정값이 추가되거나 제거되었습니다.

  • 데이터 바인딩을 만든 이후 소스 차트에서 차원과 측정값의 정의가 변경되었습니다.

데이터 바인딩 소스를 새로 고치면 차트 구성이 변경될 때 새 개체를 만들지 않고도 더하기 기호가 있는 데이터베이스 아이콘 필드 목록 메뉴에 동일한 개체를 유지할 수 있습니다.

  1. 디자이너의 오른쪽 패널에서 더하기 기호가 있는 데이터베이스 아이콘 필드 목록 메뉴를 엽니다.

  2. 수준을 두 번 클릭하여 확장합니다.

  3. 새로 고치려는 항목 위에 커서를 올려놓으십시오.

  4. 새로 고침(필드 업데이트) 아이콘을 클릭합니다.

    필드 목록 메뉴에서 수준 데이터 바인딩 새로 고침

    '필드 업데이트' 아이콘을 클릭하여 수준 데이터 바인딩 새로 고침
  5. 사용 사례에 맞게 계속하여 템플릿을 개발합니다. 여기에는 기존 콘텐츠를 재구성하거나 새 콘텐츠를 추가하는 작업이 포함될 수 있습니다. 이제 데이터 바인딩을 새로 고친 후 새로 추가된 차트 열을 더하기 기호가 있는 데이터베이스 아이콘 필드 목록 메뉴에서 사용할 수 있습니다.

Example - Looping chart images over a dimension

여기 자료 예 - 앱 내 보고의 앱 소스 예시를 참조하십시오. 앱과 데이터 파일을 공간에 업로드한 다음 앱을 다시 로드하십시오. 예제를 완료할 준비가 되었습니다.

Part 1: Add data bindings

  1. Create a new PixelPerfect template.

  2. Open the Database icon with plus symbol Field List in the designer.

    Field List menu in the PixelPerfect designer

    The 'Field List' menu expanded from the right side panel in the PixelPerfect designer
  3. Click the plus icon next to Levels.

  4. Expand Fields, and click the Plus icon next to the Region chart.

    The data binding is added.

  5. You are brought back to the main Database icon with plus symbol Field List menu. Click the plus icon next to Images.

  6. Expand the Dashboard sheet, and click the Plus icon next to the Top 5 Customers chart.

    The data binding is added.

    Field List menu showing newly created level and image data bindings

    The 'Field List' menu showing the newly created data bindings added for use: a 'Region' level and a 'Top 5 Customers' image.

Part 2: Add band and content

  1. On the design surface, right-click the Detail1 band and select Insert BandDetailReport.

  2. Open the Database icon with plus symbol Field List menu, and double-click Levels to expand it.

  3. For Region, expand the level object and drag the Region field within it onto the DetailReport1 band.

    Position the label at the top of the band.

  4. In the Database icon with plus symbol Field List menu, expand Images and drag Top 5 Customers onto the DetailReport1 band. Place it below the Region label.

You can customize and style the content as desired.

Part 3: Bind the level to the band

  1. Click the DetailReport1 band.

  2. Open the Gear Properties menu from the right side of the designer.

  3. Under Detail Report Tasks > Data Member, select the Region field.

    Report template with content and DetailReport1 band bound to level

    Report template with Detail1 band selected, and its properties opened on the right side panel. The properties show that the data binding has been connected to the band under 'Data Member'
  4. In the top right corner, click Save template.

  5. Click Preview report. Download the report and open it.

Report preview

Generated report showing several sections, one for each region, with a chart under each region heading

이 페이지가 도움이 되었습니까?

이 페이지 또는 해당 콘텐츠에서 오타, 누락된 단계 또는 기술적 오류와 같은 문제를 발견하면 알려 주십시오!