cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper V
Helper V

Multi Screen Progress Bars

End Goal:   Track question completion progress on the homescreen for all potential questions in the app.

 

Challenge:  Users can choose 4 different paths to get to 4 different sets of questions.  Each path has approximately 30 questions each spread across several pages in each path.

 

Here is general diagram screen navigation, of 2 sections( though there are 4 sections in total) to make it simpler to visualize.  The questions are sometimes as far as 4-5 screens deep in a section.  So using galleries was not an option.  This app is all individually broken into single/individual text output fields & independent input fields quite often, out of necessity. 

 

unnamed1.png

 

How do I dynamically count the total number of question related records in a database that are not currently empty?  Or count all the records that are empty.  So that the progress bars show how much is left to be answered in each section.

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Helper V
Helper V

I found this in a post written up by @R3dKap 

 

" Oh, and about counting the number of fields that are empty, here is how I would do it:

  • I would concatenate all fields from the item into a string, separating the values with commas (use the Concat function for this)
  • Then I would split the resulting string using the comma as a separator (use Split for this)
  • You will end-up with a "vertical version" of your item where each field value would be a row in the resulting collection
  • Then just use the CountIf function to count the number of fields that are not blank (or blank and substract it from the total number of columns)

Of course, if the comma could be a character entered by your users in the fields, choose another separator (like '#' or '|').  "

 

Now I'm trying to make a formula to match this.

View solution in original post

7 REPLIES 7
Highlighted
Helper V
Helper V

I found this in a post written up by @R3dKap 

 

" Oh, and about counting the number of fields that are empty, here is how I would do it:

  • I would concatenate all fields from the item into a string, separating the values with commas (use the Concat function for this)
  • Then I would split the resulting string using the comma as a separator (use Split for this)
  • You will end-up with a "vertical version" of your item where each field value would be a row in the resulting collection
  • Then just use the CountIf function to count the number of fields that are not blank (or blank and substract it from the total number of columns)

Of course, if the comma could be a character entered by your users in the fields, choose another separator (like '#' or '|').  "

 

Now I'm trying to make a formula to match this.

View solution in original post

Highlighted
Community Support
Community Support

Hi @Humanity ,

Could you please share a bit more about your data source structure?

 

Based on the needs that you mentioned, I think the Filter function and CountRows function in PowerApps could achieve your needs. Regarding the needs that you want to achieve, I assume that you have set up proper columns in your data source to store the Section name, sub name, and question name. I assume that the data structure of your data source looks like below:

| Section Name | Sub Name | Question Name |
| -------------| ---------| --------------|
| Section 1     | Sub1    |     Q1        |
|Section 1      | Sub1    |    Q2         |
....
| Section 1     | Sub 2   |      Q5       |
| Section 1     | Sub 2   |     Q6       |
...
| Section 1     | Sub 3    |      Q8      |
...
| Section 2     | Sub 1    |      Q11     |
|  Section 2    | Sub 1    |      Q12     |
...
|   Section 2   | Sub 3    |      Q18      |
...
...

 

Then within your canvas app, if you want to count total number of question related to each section in your data source that are not empty, please try the following formula:

CountRows(
       Filter(
              'Your Data Source',
              'Section Name' = " Type Specifc Section Name xxxx",   // filter records based on specific section name, e.g. Section 1
              !IsBlank('Question Name')
       )
)

or

CountIf(
        'Your Data Source',
        'Section Name' = " Type Specifc Section Name xxxx" && !IsBlank('Question Name')
)

Note: Please replace the 'Section Name', 'Question Name',... with actual column name from your own data source.

 

Please take a try with above solution, hopes it could help in your scenario.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted

Hi @Humanity ,

Could you please share a bit more about your data source structure? "

 

Combination of CDS & Excel for a few weeks

 

As for how I laid out my Canvas App... no I did not follow the way Microsoft batch automated things. I broke my screens down to individual fields and grouped them together in order to gain necessary depth and flexibility, the design freedom ended up a side benefit.  Surely a very longgggg process as my very first app ever ...lol...  But I love it, and will do it again.

 

Next month I'll have someone translate the excel workbook over to SQL, Power BI+CDS, & add an API for inter-tenant data exchanges.

 

 

 

Highlighted

Hi @Humanity , 

Is the solution I provided above helpful for your scenario?

 

For the design of your canvas app, I agree with you almost. Please check and see if the solution I provided above could help in your original issue. If you have some issue with it, please feel free to let me know here.

 

Regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted

@v-xida-msft 

 

My data input all goes into one of three optional rows, all within a single table with over 100 columns.

Highlighted

Hi @Humanity ,

Regarding the screenshot that you mentioned, I think you have come up with the Percentage value for each section. Which need do you want to achieve? Could you please show more details about your needs regarding the screenshot.

 

Please share more details about the needs you want to achieve, then we could provide a solution for you. Please give me some prompt in your screenshot.

 

Regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted

@v-xida-msft 

 

I found this in a post written up by @R3dKap 

 

" Oh, and about counting the number of fields that are empty, here is how I would do it:

  • I would concatenate all fields from the item into a string, separating the values with commas (use the Concat function for this)
  • Then I would split the resulting string using the comma as a separator (use Split for this)
  • You will end-up with a "vertical version" of your item where each field value would be a row in the resulting collection
  • Then just use the CountIf function to count the number of fields that are not blank (or blank and substract it from the total number of columns)

Of course, if the comma could be a character entered by your users in the fields, choose another separator (like '#' or '|').  "

 

I accepted this will work for now.  R3dKap is a pro or a team of pros at this.

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Top Kudoed Authors
Users online (7,361)