Just a quick question and I hope someone can help.
I am trying to make a macro which creates a new button and sets the action of this button to update a variable setting.
So far I have got the below which creates the button, names it and inserts the name of the variable to be updated but I cant seem to work out form the API what i should do next to insert the new variable value?
set newbutton = ActiveDocument.ActiveSheet.CreateButton
set prop = newbutton.GetProperties
prop.Text.v = "Remove"
set ButtonActions = prop.ActionItems
ButtonActions.Item(0).Type=31 'Macro Varible set
I am not sure what should come next...something like?