user5148719
user5148719

Reputation:

Checkbox value in Display Mode = view & edit PowerApps

Happy Thursday!

I added 2 Checkbox controls inside the TypeOfPerson field data card. Trying to figure out to display the value of the checkbox on both Display Mode = View | Display Mode = Edit

TypeOfPErson is a Column Type = Choice in SharePoint

Hope i explain myself clearly

[![enter image description here][1]][1]

Form

Edit Form

Upvotes: 0

Views: 5101

Answers (2)

SeaDude
SeaDude

Reputation: 4375

You are using two separate forms (Form1 and Form2) which is unnecessary here. You might try adding a HomeScreen then with two options "New Item" and "Search Items":

New record workflow:

  • From HomeScreen, user clicks "New Item" button
  • OnSelect of the "New Item" button:
    • NewForm(Form1)
    • Navigate(FormScreen, Fade)
  • User fills in all required fields and hits "Submit" button
  • User taken to SuccessScreen then back to HomeScreen

Search record workflow:

  • From HomeScreen, user clicks "Search Items" button
  • OnSelect of the "Edit Item" button:
    • Navigate(SearchScreen, Fade)
  • OnVisible of SearchScreen
    • ClearCollect(colItems, Filter(dataSource, status=smart))
  • Gallery control on this screen with Items property set to colItems
  • User clicks a "Right Arrow" icon within the Gallery to select a specific record from your data source to edit
  • OnSelect of the "Right Arrow"

    • EditForm(Form1) //notice, its the SAME FORM
    • Navigate(FormScreen, Fade)
  • Set the Item property of Form1 to:

    • If(Form1.Mode <> FormMode.New, gallery.Selected)

You then set the Default values of Form1 controls to something like: - If(Form1.Mode = FormMode.New, Blank(), Parent.Default

This is all from memory, so might need some minor tweaks, but the logic is there.

Upvotes: 0

Ducker
Ducker

Reputation: 198

If you can only choose one of two options, then you'll either want a dropdown or a radio.

Radio is probably better in this instance as you have only two choices. If the number of choices grows then go to a dropdown.

For the display screen why not just use a label to display the name of the option selected.

Upvotes: 0

Related Questions