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

PowerApps Label in gallery

Hello PA Community,

I have inherited a PowerApp that I am finishing up and have stumbled upon a gallery with labels in it where some of the labels turn into 'Typeable' boxes. See below:

Gallery in questionGallery in question
Apologies for the excessive blurring of headers.

 

First of all; I cannot figure out where it is set up so one specific row has 'Typeable' boxes and the rest just shows a value?


Second, in my OnSelect property of the corresponding check boxes I have the following code:

 

UpdateIf(
    colLocations,
    loc_id = ThisItem.loc_id,
    {
        invertlevel: If(
                        chk_Bundkote.Text = "Manual",
                        Value(lbl_Bundkote.Text),
                        Value(ThisItem.invertlevel)
                        ),
        invertlevel_source: ThisItem.datasource
    }
);

 

I am updating values in a collection using these checkboxes.

Now I need to add logic which enables me to write a number in the 'typeable' fields, and push that to my collection OnSelect of the check box. I have tried to add an If statement but it doesn't work as intended.

Any hints would be appreciated.

1 ACCEPTED SOLUTION

Accepted Solutions
escapethisscree
Helper I
Helper I

I discovered that a textbox had been placed on top of the label.

I adjusted my code to this and it now works:

UpdateIf(
    colLocations,
    loc_id = ThisItem.loc_id,
    {
        invertlevel: If(
                        ThisItem.datasource = "Manual",
                        Value(txt_Bundkote.Text),
                        Value(ThisItem.invertlevel)
                        ),
        invertlevel_source: ThisItem.datasource
    }
);

 

Not the smartest oversight but at least I figured it out.

View solution in original post

1 REPLY 1
escapethisscree
Helper I
Helper I

I discovered that a textbox had been placed on top of the label.

I adjusted my code to this and it now works:

UpdateIf(
    colLocations,
    loc_id = ThisItem.loc_id,
    {
        invertlevel: If(
                        ThisItem.datasource = "Manual",
                        Value(txt_Bundkote.Text),
                        Value(ThisItem.invertlevel)
                        ),
        invertlevel_source: ThisItem.datasource
    }
);

 

Not the smartest oversight but at least I figured it out.

Helpful resources

Announcements
Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Users online (1,690)