Table.Remove

variant Table.Remove ( 

table   SourceTable,

number  Position )

Example 1

Debug.ShowWindow(true);
mytable = {"One", "Two", "Three", "Four"}  ;      --Creates a table whose values are 4 strings.
removed_item = Table.Remove(mytable, 2);
for x,y in pairs(mytable) do
   Debug.Print("Index "..x.." = "..y.."\r\n");
end
Debug.Print("Removed Item ="..removed_item);

Removes the item at index 2 from the table called "mytable" and stores it's value in the variable "removed_item." In this example, the new contents of the table are printed to the debug window along with the value of the removed item. Here is what would be printed in the debug window:

Index 1 = One
Index 2 = Three
Index 3 = Four
Removed Item =Two

Tip: You can copy the action code from this example and paste it into the Action Editor to test it.

See also:  Related Actions