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

How can I clear/reset selective DataCardValue inside the form?

How do I clear some input fields inside the form before submitting? I'm not looking for ResetForm().

 

I like to clear some fields inside the form. I'm trying to setup to clear some input fields based on one user input. Is there a way to setup it up? Reset(DataCardValue) doesn't work.

1 ACCEPTED SOLUTION

Accepted Solutions
Dual Super User III
Dual Super User III

Hi @WhatisPowerApps 

 

If you want to reset a few controls inside the form, then you can create a variable to do so:
 
Control that will reset the DataCard's control: Eg. Button -> OnSelect -> Set(ResetControl,true);Set(ResetControl,false)
 
DataCard's control that will be reset: -> Reset property -> ResetControl
 
Here, ResetControl is a variable which holds the Boolean value and when it is true it will reset the conrol.
 
Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

2 REPLIES 2
Super User
Super User

the way I achieve this is to have a text input field placed inside the data card as well and make the actual field invisible.

 

I then create a variable and make this the part of the default text to the new field eg:

If(Isblank(Parent.Default),"VarText".Parent.Default)   /so the parent field to the form is blank it uses the variable field as the default text

 

Then in the default to the now invisible from field I set its Default to = The TextInput?.Text 

 

 

 

 

Dual Super User III
Dual Super User III

Hi @WhatisPowerApps 

 

If you want to reset a few controls inside the form, then you can create a variable to do so:
 
Control that will reset the DataCard's control: Eg. Button -> OnSelect -> Set(ResetControl,true);Set(ResetControl,false)
 
DataCard's control that will be reset: -> Reset property -> ResetControl
 
Here, ResetControl is a variable which holds the Boolean value and when it is true it will reset the conrol.
 
Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

Helpful resources

Announcements
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

PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

Top Solution Authors
Top Kudoed Authors
Users online (8,358)