PC Review


Reply
Thread Tools Rate Thread

Aautomating msProject from Access

 
 
JCB
Guest
Posts: n/a
 
      10th Oct 2008
I'm trying to export some data from an Access form to msProject, with the
code I presente below.
The first time I run the code it runs fine; the seconde time it gives me an
error message; the third time it runs fine again, and so on.
The error message is "The remote server machine does not exist or is
unavailable (Error 462)", and it stops at the line "Set Proj = ActiveProject"
Can anyone please tell me wath is th problem with my code?

Private Sub Command4_Click()
Dim projApp As MSProject.Application
Dim Proj As MSProject.Project
Dim varItem As Variant

Set projApp = CreateObject("MSProject.Application")

projApp.Visible = True
projApp.FileNew
Set Proj = ActiveProject

'Manipulating project
ProjectSummaryInfo Start:="01-01-2008"
For varItem = 1 To (Me.List5.ListCount - 1)
SelectTaskField Row:=1, Column:="Name"
SetTaskField field:="Name", Value:=Me.List5.Column(2, varItem)
SetTaskField field:="Start", Value:=Me.List5.Column(3, varItem)
SetTaskField field:="Finish", Value:=Me.List5.Column(4, varItem)
Next varItem

'Close project
'projApp.FileClose pjSave
'projApp.Quit
Set projApp = Nothing
Set Proj = Nothing

End Sub
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
show Data from Access in MSproject Sylvie Microsoft Access VBA Modules 1 23rd Sep 2009 02:39 PM
Macro to aAutomating report GeorgeA Microsoft Excel Misc 9 22nd Jun 2009 02:00 PM
connecting Access and MSProject =?Utf-8?B?Sk0=?= Microsoft Access External Data 0 31st May 2007 07:14 PM
Trying to acccessing the MSPROJECT Library from VBA in Access =?Utf-8?B?UEw=?= Microsoft Access VBA Modules 5 25th May 2005 02:25 PM
MSProject.Project98 field in an old Access 97 database M Skabialka Microsoft Access Forms 0 12th Sep 2003 03:16 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:30 PM.