0

I have a line of VBA code which is supposed to delete a project from MS Project Server 2010:

DeleteFromDatabase "<>\ProjectName", "User", "Password", "MSProject.mpd"

However, it returns True no matter what project name and credentials I provide. If I provide the right ones, nothing is deleted.

What is the right way to delete a project from MS Project Server?

svz
  • 4,516
  • 11
  • 40
  • 66
  • Is the DeleteFromDatabase sourcecode intrinsic, included and or do you have access to the code if not? – Jimmy Smith May 16 '14 at 14:21
  • @JimmySmith, it is a standard MSP vba function. – svz May 16 '14 at 16:18
  • Ah, do you have full admin privileges, and or ability to delete manually? If so what happens if you leave the last argument, optional formatid, off? [MSDN doc](http://msdn.microsoft.com/en-us/library/office/ff861639(v=office.15).aspx) – Jimmy Smith May 16 '14 at 16:38
  • @JimmySmith, yes, I have full privileges on server. With no last argument MSP treats the command as ODBC and shows an error cause it can't find datasource. – svz May 16 '14 at 17:18
  • I've not had this particular VBA problem, but I often have found the solution by recording a macro doing it via the interface, afterwards I tweak that code. For troubleshooting, can you record a macro to delete a test project? – Jimmy Smith May 16 '14 at 18:03
  • @JimmySmith, looks like there is no way to record a macro that would overwrite a project. The resulting macro is empty. As for deletion, looks like it's not available in MSP gui - only in server's administrative panel. – svz May 19 '14 at 09:57

0 Answers0