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

Mobile edit form item filter

I have a page (Handoff) in a mobile app that can be navigated to from two different locations. 

 

The first navigation source is from a main menu and configures the page to allow the user to select DENumber field and change the FullName field.  This function changes the owner of a piece of equipment.  DENumber is the primary column of EquipmentV2S Table and FullName is a lookup column of EquipmetV2S Tablle with values in FullName column of EmployeeList Table.

 

Dsull_2-1629680106437.png

 

 

The second navigation source is from a button on gallery list with datasource from EquipmentV2S filtered by FullName = current username.  The button sets a variable to Thisitem.DENumber, which i use as the input to the item filter on the Handoff page.  I also use a boolean variable which is set to True when navigating from the gallery list to configure the DENumber data field to 'view'.  This locks in the item that is being edited allowing the user to only change the Fullname of that item.

 

Dsull_1-1629679980131.png

 

 

I cannot get the if statement and filters to work correctly to sort the items for the Handoff page.  Refer below image for if statement and error generated.

Dsull_0-1629678846198.png

 

Any advice?

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

@Dsull ,

This is why it is always good to post your code in Text and explain where it is rather than trying to blow up and read a picture. For the Item of a Form, you need

LookUp(
   EquipmentV2S,
   DENumber=
   If(
      Handoffview,
      HandoffDamageItem,
      "09999"
   )
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

View solution in original post

7 REPLIES 7
WarrenBelz
Super User
Super User

Hi @Dsull ,

Try this

Filter(
   EquipmentV2S,
   DENumber=
   If(
      Handoffview,
      HandoffDamageItem,
      "09743M"
   )
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Thanks for the quick reponse.  I tried your filter formula and still get the error below;

 

Dsull_0-1629690260011.png

 

@Dsull ,

What type of field is DENumber and what is Handoffview (a Boolean Variable?) and HandoffDamageItem (a Text Variable?)

DENumber is text

Handoffview is Boolean

HandoffDamageItem is text

 

@Dsull ,

This is why it is always good to post your code in Text and explain where it is rather than trying to blow up and read a picture. For the Item of a Form, you need

LookUp(
   EquipmentV2S,
   DENumber=
   If(
      Handoffview,
      HandoffDamageItem,
      "09999"
   )
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

Thanks.  Apologies for not posting code, this is only my second question, so i will take note for the next time.

 

The lookup function worked. 

@Dsull ,

No problems - I have a blog on good posting practices if you have a few minutes to read it.

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

Check out the New Ideas Site

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

Top Solution Authors
Top Kudoed Authors
Users online (3,263)