Project 2003 Std. Refresh from DB

C

clicknclack

I have a stored procedure that simply inserts new
tasks into the MSP_TASKS table. All works fine (aside from some time-based
issues I still need to figure out), and, upon opening the specified project
in MS Project (2003 Standard), the newly created tasks show up in the proper
place
in the project's Gantt chart. However, I would like to be able to refresh the
Gantt chart to see tasks inserted after the initial load. Unfortunately,
pressing F9 doesn't seem to work. I've tried setting Calculation Mode to
Automatic and Manual, as well as the "Calculate Now" button on the Options
dialog's Calculation tab. Nothing seems to work except closing the project
completely and re-opening it. I'm sure I'm missing something obvious....
 
R

Rod Gill

How are you inserting the extra tasks. What are you seeing and what do you
expect to see? Do you have SP's installed? If not try.

Note that Project 2007 does not allow you to save to an ODBC database so be
aware of this when upgrade time comes around!

--

Rod Gill
Microsoft MVP for Project

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

clicknclack

Thanks for responding, Rod.

I simply wrote an SP to insert rows into MSP_TASKS (as well as set
PROJ_EXT_EDITED=1 in the related MSP_PROJECTS row). As per PJDB.HTM, I'm also
setting MSP_TASKS.EXT_EDIT_REF_DATA to '1'. I can include the full code, if
you like...

What I'm seeing is nothing in Project's Gantt chart until I close and
re-open the project, at which point the new task appears as a new row, as I
had hoped.

What I expect (or simply want - don't want to get my hopes too high, here)
is for the Gantt chart to refresh itself automatically (or manually), thus
showing the new task without the user closing and re-opening the project.

Regarding 2007, I realize that all of this could probably be accomplished
via SOAP calls to Project Server, but, given the misery that our developers
have been saddled with in setting up and configuring SharePoint, there's
little appetite here for Project as an EPM solution. I just need a quick and
simple way of auto-adding tasks for the few of us who use MSP.

Thanks again.
 
R

Rod Gill

I'm confused as this story is different from your first post. You add new
tasks into MSP_Tasks (including setting all relevant flags). Your first post
suggested they appear in their proper place, but the second post suggests
this is only after saving then re-closing?

From memory that is caused by one or more flags conflicting with another.
Try re-reading the prjdb.htm file again and be very pedantic about getting
the flags correct. Try setting flags manually in the db, sometimes a text
'1' is needed in code not a numeric 1.

I found I had to experiment a number of different ways to get an insert to
work. It's been a long time as I stopped using the MS db as 2007 does not
support it. :-(

--

Rod Gill
Microsoft MVP for Project

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

clicknclack

They do appear "in their proper place"...the first time MS Project opens
AFTER the insert. Thus, if MS Project is open when the insert occurs, the
user doesn't see the new Task until he/she has closed and re-opened the app -
saving from the app makes no difference since, until the new task is
displayed, there is nothing to save.

I have spent a goodly amount of time pondering prjdb.htm, and I'm pretty
confident that I've got the flags (int 1 for PROJ_EXT_EDITED and string '1'
w/out the delimited field list for MSP_TASKS.EXT_EDIT_REF_DATA) right.

I guess a more basic question would be: Does Project Std. 2003 EVER refresh
its GUI from its data store, be it an ODBC DB, .mpp file or anything else?
I'm beginning to suspect that the answer is "of course not - that what
Project Server is for."
 
R

Rod Gill

Project never ever refreshes from the stored file location in any version.
When a project is opened, all data is read into memory. You will need to
check if the project is closed before inserting new tasks.

--

Rod Gill
Microsoft MVP for Project

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



clicknclack said:
They do appear "in their proper place"...the first time MS Project opens
AFTER the insert. Thus, if MS Project is open when the insert occurs, the
user doesn't see the new Task until he/she has closed and re-opened the
app -
saving from the app makes no difference since, until the new task is
displayed, there is nothing to save.

I have spent a goodly amount of time pondering prjdb.htm, and I'm pretty
confident that I've got the flags (int 1 for PROJ_EXT_EDITED and string
'1'
w/out the delimited field list for MSP_TASKS.EXT_EDIT_REF_DATA) right.

I guess a more basic question would be: Does Project Std. 2003 EVER
refresh
its GUI from its data store, be it an ODBC DB, .mpp file or anything else?
I'm beginning to suspect that the answer is "of course not - that what
Project Server is for."
 

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