Sub SelectionToNewPage()Dim sr As ShapeRangeSet sr = ActiveSelectionRangesr.CutActiveDocument.AddPages 1ActivePage.ActiveLayer.Paste
End Sub
Can someone add this...
after moving the selection... immediately launch to rename the page option
Converted to VBA by ChatGPTSub MoveSelectionToNewPage() Dim sr As ShapeRange Set sr = ActiveSelectionRange If sr.Count = 0 Then Exit Sub End If Dim newPage As Page Set newPage = ActiveDocument.AddPages(1) Dim layer As Layer Set layer = newPage.ActiveLayer sr.MoveToLayer layer Dim proxy As DataSourceProxy Set proxy = Application.FrameWork.Application.DataContext.GetDataSource("WPageDataSource") proxy.InvokeMethod "OnRenamePage"End Sub
Thanking you. Working