Notifications
Clear all

[Closed] 2D arrays?

 lo1
try(destroydialog undoObj)catch()

fn add_selection arr= (append arr (selection as array))

fn delete_last_entry arr= (
	if arr.count>0 then
	(
		select arr[arr.count]
		deleteItem arr (arr.count)
		delete selection
	)
	else false
)

global undo_objects=#()

rollout undoObj "Undo Objects"
(
	button addSel "Add current selection"
	button delLast "Delete last entry"
	
	on addSel pressed do add_selection undo_objects
	on delLast pressed do delete_last_entry undo_objects
)

createdialog undoObj

Ty so much for the help , works fine

Page 2 / 2