cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
3csman
Impactful Individual
Impactful Individual

Gallery Filter

I have Gallery 1; CertsandQuals.

 

I am using the following formulate to set the default of a 'Status' toggle control. The following is working.

!IsBlank(LookUp(ECMmbrCQSmryGallery_1.AllItems,CQTitle="Firefighter I" || CQTitle="Firefighter II")) && (CountRows(ECMmbrCQSmryGallery_1.AllItems) = CountRows(Filter(ECMmbrCQSmryGallery_1.AllItems, ComplianceLabel_1.Text = "Compliant" || ComplianceLabel_1.Text = "Certified")))

 

In Gallery 1, below, because the Member profile shows less than five (5) items the toggle control should default to 'Inactive' after the data loads.

 

In order for the Member to be 'Active' the Gallery MUST have no fewer than the following five (5) 'items':

"Medical", "Fitness Test", "Live Fire Refresher", "Self-Contained Breathing Apparatus Fit Test", and EITHER "Firefighter I" or "Firefighter II". Without all five (5) items the Member is 'Inactive'. Also, inactivity can be based on 'Noncompliance'. Consequently, the existing formula and the new requirement need to all be in the new formula. 

 

Gallery.PNG

 

1. If ANY CertQualTitle shows 'Noncompliant' - Toggle Control default: 'Inactive'

 

2. If less than five (5) CertsQualsTitle items appear in Gallery 1 (regardless of titles) - Toggle Control default: 'Inactive'

 

3. If at least five (5) CertsQualsTitle items appear and the five ARE ONLY "Medical", "Fitness Test", "Live Fire Refresher", "Self-Contained Breathing Apparatus Fit Test", and EITHER "Firefighter I" or "Firefighter II", and ALL of the five (5) show 'Compliant' - Toggle Control default: 'Active'

1 ACCEPTED SOLUTION

Accepted Solutions
3csman
Impactful Individual
Impactful Individual

I worked it over a bit.

 

The below appears to be working, for now.😎

 

CountRows(ECMmbrCQSmryGallery.AllItems.CQTitle) >=5 && IsBlank(LookUp(ECMmbrCQSmryGallery.AllItems, ComplianceLabel_1.Text="Noncompliant"))

 

Thank you,

View solution in original post

2 REPLIES 2
v-bofeng-msft
Community Support
Community Support

Hi @3csman :

According to your description, the condition for toggle to be true is:

  • The value of'Compilance Status' of all records in the Gallery1 is "Noncompliant"
  • The value of CQTitle with more than 5 records in Gallery1 is one of "Medical", "Fitness Test", "Live Fire Refresher", "Self-Contained Breathing Apparatus Fit Test", "Firefighter I", "Firefighter II"]

If so,plese try this code:

CountRows(Gallery1.AllItems,CQTitle in ["Medical","Fitness Test","Live Fire Refresher","Self-Contained Breathing Apparatus Fit Test","Firefighter I","Firefighter II"])>=5 && 
IsBlank(LookUp(Gallery1.AllItems,'Compilance Status'="Noncompliant"))

Best Regards,

Bof

3csman
Impactful Individual
Impactful Individual

I worked it over a bit.

 

The below appears to be working, for now.😎

 

CountRows(ECMmbrCQSmryGallery.AllItems.CQTitle) >=5 && IsBlank(LookUp(ECMmbrCQSmryGallery.AllItems, ComplianceLabel_1.Text="Noncompliant"))

 

Thank you,

View solution in original post

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Top Solution Authors
Top Kudoed Authors
Users online (53,960)