Performance issue in adding multiple assignments

R

Ravi

Hello,
I am using MSP 2003. I have an xml file which contains 15,000 resource
assignments. I am parsing this xml in VB code and assigning the values to the
project. While doing that I am expecting a serious performance issue. The CPU
is 100% occupied and even after waiting for 30 minutes it does not complete.
By checking the time stamp at which each assignment gets uploaded to msp
file it takes around 1-2 seconds per assignment occupying 100% CPU.

Please let me know if there are any known issues on this or is there any
alternate ways to avoid this issue.
Thanks,
Ravi.
 
R

Rod Gill

There aren't any issues with this, but ways to speed it up are:

1) Create a text file of the assignments then use Project VBA to read and
add the assignments. VBA will be working in the Project process so should be
faster than VB controlling Project from a separate process.

2) Create an xml file in project format then get Project to open the xml
file. This should be fastest.

3) Create an Access or SQL database in project format and add all
assignments there then get project to open the project from the db. This
again should be quicker but is no longer supported in Project 2007.

It will help if the xml file has unique IDs for each task and resource
rather than looking for specific Task and Resource names.
--

Rod Gill
Microsoft MVP for Project

Author of the only book on Project VBA, see:
http://www.projectvbabook.com
 
R

Ravi

Thats a very useful information from Rod Gill.
I missed a point that it is VBA code that I am already using not VB code
sorry for the typo.
For a lower number of assignments setting the calculate option to manual
makes the import faster. But for for larger assignments still MSP uses 100%
CPU for a long time.(It has not completed even after 30 mins)
If we could get some pointers here in tuning this it will be better else we
have to try the other alternates.

Creating an Xml seems to be an alternate and good option. Created a small
project in MSP and saved in xml format. Opened the same with Merge to
existing project option (so that it merges with the same data which is
already there). But getting an error
'An Import error occurred.
The element <FixedCostAccural>in the <Task>element with <UID>=1 has invalid
data.
The accural choice is not valid. Type start, prorated or end.
(check in xml it is 0) Possibly this is a bug in MSP itself.
 
R

Rod Gill

What SP level are you at? You should be at least to SP2.

application.ScreenUpdating=false
at the beginning of the code then

application.ScreenUpdating=true

at the end may also speed things up.

If you need to force Project to give other processes some CPUY cycles then
add a DoEvents in your main loop will return control to the Operating system
for a time slice or two.


Author of the only book on Project VBA, see:
http://www.projectvbabook.com
 
R

Ravi

Hi,
Installed service pack3.
Set application.ScreenUpdating=false
Still the same issue, CPU is 100% occupied and it does not complete even
after waiting for 30 minutes.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top