In MSProject, Module1: References Visual Basic for Applications Microsoft Project 14.0 Object Library OLE Automation Microsoft Office 14.0 Object Library Option Explicit Public Sub ReportDatesExport() 'Copyright (c) 2013 Richard M. Bixler, All Rights Reserved. Do not delete this copyright notice. 'Runs with "ctl-t" from MSProject UI. Dim thisProject As Project Dim fileName As String, filePath As String, mapName As String, meFileName As String Dim msgBoxResponse As VbMsgBoxResult Set thisProject = ActiveProject fileName = thisProject.Name filePath = thisProject.Path If InStrRev(fileName, ".", , vbTextCompare) > 0 Then fileName = Left(fileName, InStrRev(fileName, ".", , vbTextCompare) - 1) If InStr(1, LCase(fileName), "rollup", vbTextCompare) <= 0 Then msgBoxResponse = MsgBox("Export from Rollup. Click Ok to continue anyway, Cancel to abort.", vbOKCancel, "Export Rollup") If msgBoxResponse = vbCancel Then Exit Sub End If updateTaskUID mapName = "ReportDatesExport" createMap mapName:=mapName FileSaveAs Name:=filePath & "/" & fileName & ".xlsx", FormatID:="MSProject.ACE", map:=mapName 'FileSaveAs Name:=filePath & "/" & fileName & ".xls", FormatID:="MSProject.XLS5", map:=mapName End Sub Private Sub createMap(ByVal mapName As String) 'Copyright (c) 2013 Richard M. Bixler, All Rights Reserved. Do not delete this copyright notice. MapEdit Name:=mapName, Create:=True, OverwriteExisting:=True, DataCategory:=pjMapTasks, CategoryEnabled:=True, TableName:="Task_Table1", _ FieldName:="Name", ExternalFieldName:="Name", HeaderRow:=True, AssignmentData:=False, TextFileOrigin:=0, UseHtmlTemplate:=False, IncludeImage:=False MapEdit Name:=mapName, DataCategory:=pjMapTasks, FieldName:="Start", ExternalFieldName:="Start_Date" MapEdit Name:=mapName, DataCategory:=pjMapTasks, FieldName:="Finish", ExternalFieldName:="Finish_Date" 'Use ribbon Project>Custom Fields to rename text field to "RollupTaskUID". This one used Text14 MapEdit Name:=mapName, DataCategory:=pjMapTasks, FieldName:="RollupTaskUID", ExternalFieldName:="RollupTaskUID" MapEdit Name:=mapName, DataCategory:=pjMapTasks, FieldName:="Notes", ExternalFieldName:="Notes" MapEdit Name:=mapName, DataCategory:=pjMapTasks, FieldName:="UniqueID", ExternalFieldName:="UniqueID" MapEdit Name:=mapName, DataCategory:=pjMapTasks, FieldName:="TaskMilestone", ExternalFieldName:="TaskMilestone" End Sub Private Sub updateTaskUID() 'Copyright (c) 2013 Richard M. Bixler, All Rights Reserved. Do not delete this copyright notice. Dim thisProject As Project Dim fileName As String, filePath As String, strText14 As String, targetProgramName As String, programName As String, test As String Dim lastRollupTaskUID As Double Dim thisTask As Task, lastRollupTaskUIDsave As Task Set thisProject = ActiveProject filePath = thisProject.Path If InStrRev(thisProject.Name, ".", , vbTextCompare) > 0 Then fileName = Left(thisProject.Name, InStrRev(thisProject.Name, ".", , vbTextCompare) - 1) Else fileName = thisProject.Name lastRollupTaskUID = -1 programName = "" For Each thisTask In thisProject.Tasks If LCase(thisTask.Name) = "last rolluptaskuid" Then 'Capture LastModuleTaskUID from thisTask field Text14, and convert to a double. Set lastRollupTaskUIDsave = thisTask strText14 = thisTask.Text14 lastRollupTaskUID = Val(strText14) End If targetProgramName = Left(fileName, Len(fileName) - Len("_Rollup")) & " " & "ProgramName" If InStr(1, thisTask.Name, targetProgramName, vbTextCompare) Then programName = Mid(thisTask.Name, Len(targetProgramName) + 3, Len(thisTask.Name) - (Len(targetProgramName) + 3)) End If If programName <> "" And lastRollupTaskUID > -1 Then Exit For Next thisTask 'now scan all tasks and assign incremenal RollupTaskUID values into blank ones For Each thisTask In thisProject.Tasks If Not thisTask Is Nothing Then test = thisTask.Name strText14 = thisTask.Text14 If strText14 = "" Then lastRollupTaskUID = lastRollupTaskUID + 1 thisTask.Text14 = programName & Format(lastRollupTaskUID, "00000") End If End If Next thisTask lastRollupTaskUIDsave.Text14 = lastRollupTaskUID End Sub Public Sub deleteTask() Dim thisTask As Task Dim msgYesNo As VbMsgBoxResult Set thisTask = ActiveCell.Task msgYesNo = MsgBox("Delete selected tasks?", vbYesNo + vbQuestion + vbDefaultButton2) If msgYesNo = vbYes Then thisTask.Delete End Sub