cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
balys
Frequent Visitor

Can not save toggle value

Hello All,

This is my second attempt for help regarding Powerapp set up. 

Current set-up: I have a one Screen with 3 toggles: Toggle11/Toggle11_1/Toggle11_2 by default they say No. 

 

With the help of visible I created a wizard like set up - 3 questions needs to be answered YES/NO 

 

I want to configure a Finish button when the selections of toggles would be saved to the SQL DB. 

 

I have 

If(Toggle11.Value = true, Patch( Settings, LookUp( Settings, SettingName = "EnableAllDiagnosticPolicies" ), { SettingValue: "1" } ), Patch( Settings, LookUp( Settings, SettingName = "EnableAllDiagnosticPolicies" ), { SettingValue: "0" }))

 

Which work. 

I want to add another Toggle SETTING 

If(Toggle11_1.Value = true, Patch( Settings, LookUp( Settings, SettingName = "RemediateAllDiagnosticPolicies" ), { SettingValue: "1" } ), Patch( Settings, LookUp( Settings, SettingName = "RemediateAllDiagnosticPolicies" ), { SettingValue: "0" }));

 

AND fail: 

balys_0-1643027470308.png

 

Tried separating these IF statement with AND / O / Semi-colon ";" / && 

 

What I is the best IF statement separator? What I am doing wrong? 

 

Thanks in advance,

Balys

 

 

 

3 REPLIES 3
balys
Frequent Visitor

Fixed it myself. 

C-Papa
Super User
Super User

Concurrent(

Patch(Settings, LookUp( Settings, SettingName = "EnableAllDiagnosticPolicies" ),
{SettingValue:
If(Toggle11.Value,"1" ,"0"}) )

,

Patch(Settings, LookUp( Settings, SettingName = "RemediateAllDiagnosticPolicies" ),
{SettingValue: If(Toggle11_1.Value,"1" ,"0")} )

)

 

 

 

Hi @balys ,

 

I'm very glad your problem is solved and hope your sharing can help more people in the forum. 

 

Best Regards,

Jessica Gu

 

 

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Difinity Conference 2022

Difinity Conference 2022

Register today for two amazing days of learning, featuring intensive learning sessions across multiple tracks, led by engaging and dynamic experts.

European SharePoint Conference

European SharePoint Conference

The European SharePoint Conference returns live and in-person November 28-December 1 with 4 Microsoft Keynotes, 9 Tutorials, and 120 Sessions.

Power Apps Ideas

Changes to Ideas Coming

We are excited to announce a new way to share your ideas for Power Apps!

Top Solution Authors
Top Kudoed Authors
Users online (5,085)