Import and submit surrogate timesheets

Mar 25, 2010 at 1:16 PM

Hi!! I am trying to import and submit surrogates timesheets, but my code doesn´t work!! There aren´t any exceptions or errors during the process but the hours from the surrogate timesheet aren´t sent to Project.

Here is my pseudo-code:


foreach (KeyValuePair<Guid, string> kvpUsers in dicUsers)
                    {//por cada usuario, tiene que loguearse, importar y desconectar
                        if (login.connect(false, kvpUsers.Value, "temporal"))
                        { //se loguea el usuario por formularios
                            bool res = submitStatusToProject(date, kvpUsers.Key, kvpUsers.Value);
                            if (login.disconnect())
                            {//se desconecta el usuario

foreach (User)


  if (loginForms.Login ( userName, userPass) )


       statusingWS.ImportTimesheet(periodGuid); statusingWS.SubmitStatus(null, "Status submitted: " + DateTime.Today);









Mar 29, 2010 at 1:13 PM

Hi! I have found the solution! I use the Project Server impersonation in each user to import and submit their status.