2002 versus 2003 FileSaveAs Issue

  • Thread starter Microsoft Business Solutions Newsgroups
  • Start date
M

Microsoft Business Solutions Newsgroups

I'm getting an error trying to run a simple Project add-in that we had
working with our previous software version and Office 2002. Now in our new
version (but no changes to this part of the app) and trying to use Project
2003, I get an error.

Details:
Using c:\Program Files\Microsoft office\Office11\MSPRJ.OLB

When I use project's MSProject object's FileSaveAs I get a SQL 208 error
from this statement:

declare @P1 int
set @P1=2
exec sp_prepexec @P1 output, NULL, N'select Name from Project where Name =
''DBCTest101'''
select @P1

The previous version of Office generated a different statement, that worked:

declare @P1 int
set @P1=-1
exec sp_prepexec @P1 output, NULL, N'select distinct(PROJ_ID) from
MSP_PROJECTS where PROJ_NAME = ''DBCTest101'' '
select @P1

Is there something I've done wrong or need to update? The table "Project"
does not exist in my project database, but I don't know how it's obtaining
that table name.

The call to FileSaveAs has the following parameters in my VB 6 application:

"<" & oAddinRegistry.GetProjectDSN & sODBCParms & " >\" &
txtProjectName.Text
, , ,
, , , ,gsID
,gsPWD ,"MSProject.ODBC"
 
M

Microsoft Business Solutions Newsgroups

The original message is from (e-mail address removed) - I don't know
how to set the "FROM" in Outlook Express for this newsgroup.
 
L

Lars Hammarberg

It seems like you're running the 2002 version against a Project saved via
ODBC to the database - thus using the Project OLEDB provider (containing the
Project database) - and when running 2003 you're accessing a plan saved to
Projectserver.
The Enterprise ProjectServer FileSaveAs method does not use the
MSProject.ODBC parameter.
 
M

Microsoft Business Solutions Newsgroups

Thanks for your comment. Unfortunately I'm still stuck. MSDN doesn't have
an alternative approach, or at least I'm not understanding it. I have a
database that I want to write the information to - the one that 2002
information was written to. Do you know how I need to change the parameters
to use the ODBC connection string I provided and get the data into the SQL
Server db I have? Do I need to do anything to the database first? Is this
even possible, and if not, how else can I make this work?

Thanks!

Darrick Coles
 
M

Microsoft Business Solutions Newsgroups

Anyone have any advice on this one?

(e-mail address removed)
 
R

Rod Gill

Hi,

So do you have Project Server? If so, what version? If you are using Project
2003 Professional and Project Server 2003 then File, Save As saves to
Project Server and will cause problems and you will need a modified
Com-Addin. If you don't have Project Server at all, then the add-in should
work. This is basically what Lars said.
 
M

Microsoft Business Solutions Newsgroups

I tried this on a virtual PC image with a new install of Project
Professional 2003 - no server. It did not work, it gave the error I
mentioned. My intial configuration was on a machine that was attached to
Project Server and I thought that might be the problem. I was able to save
out to Project Server, but that's not what I want to do - I want to use the
ODBC connection as I did before. This did not work for me without Project
Server involved. So the question still stands, is there a way to make this
work with ODBC? Am I doing something wrong (have you seen this work with
Project 2003 - I noticed the error when running SQL Profiler - project did
not surface the error).
 
M

Microsoft Business Solutions Newsgroups

My last attempt before opening a case with Microsoft...

I thought that perhaps the problem was that I had installed Project
Professional, so I uninstalled Professional and installed Project Standard.
The behavior was the same.
 

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