cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Solarioc
Level: Powered On

ThisItem statement not pulling through

I have a label that has this statement "Notes: " & Thisitem.AdditionalItems It doesn't give me a red x so it works and the notes appears but nothing pulls through. Has anyone seen this by chance?Excel_OneDrive.JPGThisitemstatement.JPG

15 REPLIES 15
Super User
Super User

Re: ThisItem statement not pulling through

 

I assume you are using a ThisItem to get the computer and dock names so it is working for other entities, right? You could look at the collection to verify that the 'AdditionalItems' column is there and maybe try an alternative approach like LookUp to see if that works. 

 

I have encountered times when the ThisItem was in an error state but it didn't show the error, usually when I copied a gallery from somewhere and remapped the data source but forgot to change some of the references.

Solarioc
Level: Powered On

Re: ThisItem statement not pulling through

What would a lookup statement look like?

Super User
Super User

Re: ThisItem statement not pulling through

Since it looks like you are working in Excel, using the computer/dock name would be best I would think (as opposed to an ID or something like that). Assuming the Excel file is named ComputerList, the column with the computer and dock items is named Computers, and the text box with the computer/dock name in your gallery is named ComputerTextBox, the LookUp would look like:

 

LookUp(
     ComputerList,
     Computers = ComputerTextBox.Text,
     AdditionalItems
)

 

 

Super User
Super User

Re: ThisItem statement not pulling through

I forgot the Notes text. It would look like this with that included:

"Notes: " &
LookUp(
     ComputerList,
     Computers = ComputerTextBox.Text,
     AdditionalItems
)

 

 

Solarioc
Level: Powered On

Re: ThisItem statement not pulling through

"Notes: " & LookUp(Devices,AdditionalItems = DeviceGallery,selected.additionalitems

 

 

The actual gallery I have everything displayed in is 'DeviceGallery'

 

The column for the item is 'additionalitems'

 

The doc (On OneDrive) is Device-Order-Data

 

The tab on the doc is Devices

 

 

Super User
Super User

Re: ThisItem statement not pulling through

Your formula is close but needs some adjusting.

 

Let me put an explanation of the LookUp function in. The syntax is like this: 


LookUp(Table, Formula, Column to Display From).

 

The Table would be your data source, which from what you said should be Devices.

 

The Formula is a comparison of two items and can be explicit, like Flavor = "Chocolate", or part of a reference, which is what we are doing. So, we would need the name of the column (from the Devices table) that has the "HP Elitebook 350 G3", etc. in it and then the name of the label in DeviceGallery that has that text in it. I attached a screenshot below to hopefully help with that explanation. So if the column where the "HP Elitebook 350 G3" and other items are found is called DeviceName, and the label in the gallery where that text is displayed is called DeviceNameText, it would be DeviceName = DeviceNameText.Text. 

 

The Column to Display From is the column that you want to display the corresponding value from. In your case, it sounds like additionalitems should be what you need. You don't need the Selected in there, just the column name. 

 

In my example below, my data source is a table named Table1 from an Excel file named ScheduleTestData. The label with "136" in it has the formula ThisItem.EmployeeID in the Text field and is named Label3. I want to look up what is in the Location column based on whatever text is in Label3 by comparing it to the EmployeeID column in Table1.

 

2018-08-02(1).jpg

 

Hopefully that helps a bit. So, we need the column name and label name where "HP Elitebook 350 G3" is to complete the LookUp.

Solarioc
Level: Powered On

Re: ThisItem statement not pulling through

I am sorry. For some reason it is not clicking. 

I am getting closer, here is my formula I built

 

LookUp(Devices, Title = Label5_1,Text(AdditionalItems)

 

 

The actual gallery I have everything displayed in is 'DeviceGallery'

 

The column for the item is 'additionalitems'

 

Column for 850 g3 is 'title'

 

Label name for computer name is 'Label5_1'

 

The doc (On OneDrive) is Device-Order-Data

 

The tab on the doc is Devices

Super User
Super User

Re: ThisItem statement not pulling through

No worries! Your formula is pretty much there aside from one change. Make it: 

 

LookUp(Devices, Title = Label5_1, AdditionalItems)

 

That should work but if not, we'll keep at it until we get there. 

Solarioc
Level: Powered On

Re: ThisItem statement not pulling through

No Dice... but I was close I attempted that one above. It is giving me an invalid argument error. Thanks again

 

Here is the Table

Capture.JPG

 

 

Here is my gallery

Gallery.JPG

 

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors
Users Online
Currently online: 330 members 5,812 guests
Please welcome our newest community members: