But redo operation restored the section,
when i made an action section in next VBA macro.
Here, all process had to be surrounded by
BeginUndoScope and EndUndoScope.
Sub Macro2()
Dim UndoScopeID1 As Long
UndoScopeID1 = Application.BeginUndoScope("UndoRedoTest")
Application.Windows.ItemEx("UndoRedoTest.vsd").Activate
Application.ActiveWindow.Page.Drop
Application.Documents.Item("C:\Documents and Settings\yoda\My
Documents\UndoRedoTest.vsd").Masters.ItemU("Master.0"), 3.543307, 8.267717
Application.ActiveWindow.Page.Shapes.ItemFromID(1).OpenSheetWindow
Application.ActiveWindow.Shape.AddSection visSectionAction
Application.ActiveWindow.Shape.AddRow visSectionAction, visRowLast,
visTagDefault
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionMenu).FormulaU = """"""
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionPrompt).FormulaU = """"""
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionHelp).FormulaU = """"""
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionAction).FormulaU = """"""
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionChecked).FormulaU = "0"
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionDisabled).FormulaU = "0"
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionReadOnly).FormulaU = "FALSE"
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionInvisible).FormulaU = "FALSE"
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionBeginGroup).FormulaU = "FALSE"
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionTagName).FormulaU = """"""
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionButtonFace).FormulaU = """"""
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionSortKey).FormulaU = """"""
Application.ActiveWindow.Shape.CellsSRC(visSectionAction, 0,
visActionMenu).FormulaU = """test"""
Application.ActiveWindow.Close
Application.EndUndoScope UndoScopeID1, True
End Sub