Problem involving the Interop for MS Project 2003.
-
Wednesday, 4 August 2010 1:42 PM
I'm running VS2005 and MS Project 2003. I'm writing a custom Winforms app that, among other things, calls up an instance of MS Project 2003 and loads and manipulates an MPP file. (I can't remember if I've asked before but how common is this sort of thing?)
The display of the MPP file is the default. List of tasks on the left, Gantt chart on the right.
My problem is this: How do I programatically manipulate the date setting on the Gantt Chart? That is, set it so the first day displayed is the same as the start date of the first task displayed on the left?
All Replies
-
Wednesday, 4 August 2010 2:09 PMModerator
Hi,
I do not know all the stuff you have to add for Interop, but here are the objects:
The instruction is application.editgoto, with two options:
editgoto id:=xxx 'positions the timescale such that task id xxx will be visible
editgoto date:="xx/yy/ZZZ" 'positions the timescale such that xx/yy/zzz appears on the left.
Greetings,
- Marked As Answer by B. Chernick Wednesday, 4 August 2010 3:42 PM
-
Thursday, 5 August 2010 10:40 AMModeratorHI,It is a common task to manipulate Project via automation.Author of the only book on Project VBA, see: http://www.projectvbabook.com
"B. Chernick" wrote in message news:103ae472-e5d5-46fd-ad96-049b1d4d2771...I'm running VS2005 and MS Project 2003. I'm writing a custom Winforms app that, among other things, calls up an instance of MS Project 2003 and loads and manipulates an MPP file. (I can't remember if I've asked before but how common is this sort of thing?)
The display of the MPP file is the default. List of tasks on the left, Gantt chart on the right.
My problem is this: How do I programatically manipulate the date setting on the Gantt Chart? That is, set it so the first day displayed is the same as the start date of the first task displayed on the left?
__________ Information from ESET Smart Security, version of virus signature database 5342 (20100805) __________
The message was checked by ESET Smart Security.
http://www.eset.com
The one and only Project VBA Book Rod Gill Project Management