cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Boneckrh19
Level 8

The difference between ThisItem and Gallery.Selected

I am setting a variable on the next arrow of a gallery.

Set(_selectedItem, Gallery.Selected)

When I try to use this variable to refer to a record for deletion, the Remove() function will not accept my variable.

Remove(Entity, _selectedItem)

However if I change my Set() statement to this

Set(_selectedItem, ThisItem)

it does work. Either one appears to work for RemoveIf, and for every other function I have tried. What exactly is the difference between ThisItem and Gallery.Selected that specifically the Remove function would only work with one?

3 REPLIES 3
Community Support Team
Community Support Team

Re: The difference between ThisItem and Gallery.Selected

Hi @Boneckrh19 ,

 

Syntax

Set( VariableName, Value )

  • VariableName - Required. The name of a global variable to create or update.
  • Value - Required. The value to assign to the context variable.

However, Gallery.selected it can be seems as one variable,you can use, Remove(datasource,Gallery.selected)

 

More information:

function-set

 

Hope this could be helpful.

 

Best Regards.

Yumia

Administrator
Administrator

Re: The difference between ThisItem and Gallery.Selected

Thanks for posting in the community @Boneckrh19 - can you review the above reply and advise if it was helpful?

 

@TopShelf-MSFT 

Boneckrh19
Level 8

Re: The difference between ThisItem and Gallery.Selected

I was wondering if there were any differences besides the fact that Remove does not work with Gallery.Selected, and also why that would be the case. This information is not in the documentation.