Thanks so much for trying this out. You've verified that it's possible to get this working.

However, when I execute the same code, the file "p2.csv" is exactly same size as p1.mpp and contains binary data, not the text. Since you have it working it must be a bug in either my version of MSProject or win32com. I'm using:

MSProject 2003
Python 2.5.2
pywin32-210

Could you verify which versions you tested with?

Tim Golden wrote:

<code>
import win32com.client

project = win32com.client.Dispatch ("MSProject.Application")
project.FileOpen ("c:/temp/p1.mpp")
project.FileSaveAs (Name="c:/temp/p2.csv", FormatID="MSProject.CSV", Map="p1")
project.FileClose (Save=0)
project.FileQuit ()

</code>

I hadn't thought to check but, yes, it is:

<p2.csv>
Name,Actual_Cost
Do something,£0.00
</p2.csv>

Sorry not to be much more help; I'm not really an MS Project man myself.

TJG

_______________________________________________
python-win32 mailing list
python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32

Reply via email to