Skip to main content

Issues update on #projectserver2013 - Timesheets and Publishing

Reporting Publish
** updated with links to other related discussions, and a VBA macro **

the following issue has been noted on publish since June 13 CU was applied:


ReportingProjectChangeMessageFailed (24006) - Object reference not set to an instance of an object.. Details: id='24006' name='ReportingProjectChangeMessageFailed' uid='4d869e56-f625-e311-bb41-005056b90052' QueueMessageBody='Project UID='e3f49977-b2bc-e211-8559-005056b90052'. PublishType='ProjectPublish'' Error='Object reference not set to an instance of an object.'.


I have seen this noted previously on a similar issue:

http://nearbaseline.com/blog/2013/06/ms-reporting-project-publish-jobs-failed-after-aprilcu/comment-page-1/#comment-14741

This is  caused by Baselined Milestones having NULL Baseline Cost values
Original bug note with potential workaround is here:


The following macro (from MS) is designed to resolve this:
NOTE:  I am providing NO warranty for this!


'DISCLAIMER OF WARRANTY
'
'THIS FIX CODE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND.
'MICROSOFT FURTHER DISCLAIMS ALL IMPLIED WARRANTIES INCLUDING WITHOUT
'LIMITATION ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR OF FITNESS
'FOR A PARTICULAR PURPOSE. THE ENTIRE RISK ARISING OUT OF THE USE OR
'PERFORMANCE OF THE CODE REMAINS WITH YOU.
'
'IN NO EVENT SHALL MICROSOFT OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES
'WHATSOEVER (INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF
'BUSINESS PROFITS, BUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION,
'OR OTHER PECUNIARY LOSS) ARISING OUT OF THE USE OF OR INABILITY TO USE
'THIS MACRO, EVEN IF MICROSOFT HAS BEEN ADVISED OF THE POSSIBILITY OF
'SUCH DAMAGES. BECAUSE SOME STATES DO NOT ALLOW THE EXCLUSION OR
'LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES, THE
'ABOVE LIMITATION MAY NOT APPLY TO YOU.



'This macro attempts to work around the reporting publish failure that occurs when there are tasks

'with baselines and where the BaselineCost contour is NULL. The symptoms that you see in the queue
'for the "Reporting (Project Publish)" job has details similar to:
'
'
'
'uid="c72e20a7-9b7f-487b-9da2-19460b2e6c32"
'QueueMessageBody="Project UID='8e074f24-1064-47dd-bce5-c2dad8d556c8'.
'PublishType='ProjectPublish'" Error="Object reference not set to an instance of an object." />


'This code simply walks through the tasks in the tasks in the project and if there are

'baseline(s) set, then the code sets a time scaled baseline cost = 0 on the day prior to
'where the baseline start is scheduled.  This sets the baseline contour so that the
'"Object reference not set to an instance of an object" problem can be overcome during the
'reporting publish job.

Sub FixPublish()


Dim t As Tasks

Dim tsv As TimeScaleValues
Dim i As Long
Dim bCalc As Boolean

On Error Resume Next


'get the current application calculation state

bCalc = Application.Calculation
'set calculation to manual (helps with performance while the code runs)
Application.Calculation = pjManual

Set t = ActiveProject.Tasks


'walk through the tasks in the project. If a task as a baseline(s) then set a timescaled baselinecost = 0

For i = 1 To t.Count
    If Not t(i) Is Nothing Then
        If t(i).BaselineStart <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).BaselineStart - 1, t(i).BaselineStart - 1, pjTaskTimescaledBaselineCost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline1Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline1Start - 1, t(i).Baseline1Start - 1, pjTaskTimescaledBaseline1Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline2Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline2Start - 1, t(i).Baseline2Start - 1, pjTaskTimescaledBaseline2Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline3Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline3Start - 1, t(i).Baseline3Start - 1, pjTaskTimescaledBaseline3Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline4Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline4Start - 1, t(i).Baseline4Start - 1, pjTaskTimescaledBaseline4Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline5Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline5Start - 1, t(i).Baseline5Start - 1, pjTaskTimescaledBaseline5Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline6Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline6Start - 1, t(i).Baseline6Start - 1, pjTaskTimescaledBaseline6Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline7Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline7Start - 1, t(i).Baseline7Start - 1, pjTaskTimescaledBaseline7Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline8Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline8Start - 1, t(i).Baseline8Start - 1, pjTaskTimescaledBaseline8Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline9Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline9Start - 1, t(i).Baseline9Start - 1, pjTaskTimescaledBaseline9Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
        If t(i).Baseline10Start <> "NA" Then
            Set tsv = t(i).TimeScaleData(t(i).Baseline10Start - 1, t(i).Baseline10Start - 1, pjTaskTimescaledBaseline10Cost, pjTimescaleDays)
            If tsv(1).Value = "" Then
                tsv(1).Value = 0
            End If
        End If
    End If
Next

'fix the project summary task

With ActiveProject.ProjectSummaryTask
    If .BaselineStart <> "NA" Then
        Set tsv = .TimeScaleData(.BaselineStart - 1, .BaselineStart - 1, pjTaskTimescaledBaselineCost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline1Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline1Start - 1, .Baseline1Start - 1, pjTaskTimescaledBaseline1Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline2Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline2Start - 1, .Baseline2Start - 1, pjTaskTimescaledBaseline2Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline3Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline3Start - 1, .Baseline3Start - 1, pjTaskTimescaledBaseline3Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline4Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline4Start - 1, .Baseline4Start - 1, pjTaskTimescaledBaseline4Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline5Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline5Start - 1, .Baseline5Start - 1, pjTaskTimescaledBaseline5Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline6Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline6Start - 1, .Baseline6Start - 1, pjTaskTimescaledBaseline6Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline7Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline7Start - 1, .Baseline7Start - 1, pjTaskTimescaledBaseline7Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline8Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline8Start - 1, .Baseline8Start - 1, pjTaskTimescaledBaseline8Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline9Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline9Start - 1, .Baseline9Start - 1, pjTaskTimescaledBaseline9Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
    If .Baseline10Start <> "NA" Then
        Set tsv = .TimeScaleData(.Baseline10Start - 1, .Baseline10Start - 1, pjTaskTimescaledBaseline10Cost, pjTimescaleDays)
        If tsv(1).Value = "" Then
            tsv(1).Value = 0
        End If
    End If
End With
            
'set the application calculation state back the way it was
Application.Calculation = bCalc
            
End Sub




Timesheets created without Admin tasks


Here's another thats not been reproduced yet, but I am receiving notifications from a customer that some users are seeing their timesheets created without Admin Tasks


Now there was an issue with this under delegation from 2010 days (2010 - http://support.microsoft.com/kb/2553504 ) but again I have been unable to reproduce as of yet.


to isolate and resolve the issue I ran the following once the issue had occurred.  This doesnt repro the problem.


I delegated as user 

opened timesheet and submitted 
at this point i noted the error but also saw that the timesheet did submit 
Recalled and deleted timesheet (taking note of actual hours logged for reference) 
Recreated timesheet and got the following error:

"the timesheet creation failed because of problems with the project web app or with data validations" 


Noted that Admin Tasks had not been added to the timesheet 

Manually added these 
Submitted timesheet 
no issue noted

Comments

  1. This comment has been removed by the author.

    ReplyDelete
  2. Hi Carl,

    Been a while! :) Have you tried testing with baselines when reproducing that one? That nearbaseline blog talks about a regression from AprilCU which is still pending a fix from Microsoft. They were talking OctCU but I don't know.. I'd be interested to know if it's a new issue or the same.

    ReplyDelete
  3. Hey chap indeed, loooong time!!
    Yeah I'm just surprised it's not had as much publicity. I haven't been able to repro it though (my lab is on June cu) so I'm thinking there must be something else in the trigger for this

    ReplyDelete

Post a Comment

Popular posts from this blog

SP2 released

Office Project Server 2007 Sp2 has now been released.  see the details here - http://blogs.msdn.com/chrisfie/archive/2009/04/28/announcing-service-pack-2-sp2-for-microsoft-project-2007-and-microsoft-project-server-2007.aspx .  see teh webcast here http://blogs.msdn.com/brismith/archive/2009/04/28/project-server-2007-service-pack-2-sp2-is-now-available.aspx Blogged with the Flock Browser

TPG Apps Highlights - Risk Matrix #projectonline #projectserver #risk

This post is the first of a series to highlight the apps available for Project Server and Project Online from the SharePoint store  ( https://store.office.com/search.aspx?productgroup=SharePoint&qu=tpg ) and direct via your local TPG office. The first of this series will look at the s imple plug-and-play apps that all users of Project Online can make use of quickly and easily.   T hese are: Risk Matrix  Milestone Trend Analysis (MTA) WBS Chart viewer Next we will focus on the challenge of  Resource Request Supply and Demand by demonstrating our more recent TeamLink and TeamManager apps. Team Manager App is a Resource Manager/Owner app for allocating resource supply to Projects and BAU activities and monitoring demands against commitments Team Link App is a PM tool for monitoring Project demands vs the supply provided by the Resource Managers  Finally I will highlight some of the benefits of our integration tools when used i...

Restoring PWA Site to another Web App in the same Farm

The scenario is this: SharePoint 2016 Farm with Project Server Two Web Apps Development UAT One PWA on Development Web App. I want to copy the PWA Site on Development web app to UAT to support a testing cycle. As far as I knew there were two options: 1) Content Database Restore and Attach Process would be backup your Dev Content Database, Restore to a new Content Database for QA, then mount the database on the appropriate web app and your off.... Problem:  Although you can do this with the -AssignNewDatabaseID switch in Powershell (to avoid two content db's having the same database id) the Site Collection (PWA) in the db still retains its SiteID which means there is a duplicate SiteID in the Configuration Database.  This stops the PWA site being created and alllocated correctly and becomes essentially orphaned. This method is only any good for MOVING not COPYING Back to the drawing board... 2) Backup-SPSite / Restore-SPSite I didn't believe this ...