|
 |
 |
 |
 |
Microsoft Knowledge Base Article
This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved. Terms
of Use |
Trademarks
Article ID: 867742 - Last Review: September 18, 2011 - Revision: 5.0 You cannot access a PDS extension from Project Server 2003Important This article contains information about modifying the registry.
Before you modify the registry, make sure to back it up and make sure that you
understand how to restore the registry if a problem occurs. For information
about how to back up, restore, and edit the registry, click the following
article number to view the article in the Microsoft Knowledge Base: 256986Â
(http://kbalertz.com/Feedback.aspx?kbNumber=256986/
)
Description of the Microsoft Windows Registry You cannot access a custom Project Data Service (PDS)
extension from Microsoft Office Project Server 2003. However, calls to the
standard published Project Server PDS file name extensions work as
expected. This problem occurs when the PDS extension does not meet the
following guidelines:
- The PDS extension does not resend the correct XMLRequest method.
- The PDS extension is registered as COM objects.
- The PDS extension is registered with the Project Server PDS
extensions.
Microsoft provides programming examples for illustration only,
without warranty either expressed or implied. This includes, but is not limited
to, the implied warranties of merchantability or fitness for a particular
purpose. This article assumes that you are familiar with the programming
language that is being demonstrated and with the tools that are used to create
and to debug procedures. Microsoft support engineers can help explain the
functionality of a particular procedure, but they will not modify these
examples to provide added functionality or construct procedures to meet your
specific requirements.
To resolve this problem, follow these steps:
- The PDS extension can call a PDS Extender when the extender
implements a public function named XMLRequest that has one of the following code signatures, depending on the
program that you are running:
- The following code signature is for Microsoft Visual
Basic 6:
Public Function XMLRequest( _
ByVal sXML As String, _
ByVal sUser As String, _
ByVal sConnect As String, _
ByVal lDBType As Long, _
ByRef nHandled As Integer) _
As String
- The following code signature is for Microsoft
.NET:
[ComVisible(true)]
public string XMLRequest(_
string Xml, _
string User, _
string Connect, _
int DatabaseType, _
ref short Handled)
- The following code signature is for .NET (XMLRequestEx
variant ):
[ComVisible(true)]
public string XMLRequestEx(string sXML, string sPDSInfoEx,
ref short nHandled)
- Register the PDS as a COM object. To do this, follow these
steps:
- Set the class with the required attributes for COM
interoperability.
- Generate a new GUID by using the Uuidgen.exe program
for each new class.
The following is an example of how to use the
Uuidgen.exe program for each new class to generate a new
GUID:
[Guid("EAA49654-65E3-4BC5-BCC7-E465264323D5"),
ComVisible(true),
ClassInterfaceAttribute(ClassInterfaceType.AutoDual)] - Add the XMLRequestEX() method by using the required parameter layout.
- Add the method calls that validate the request and
provide error handling.
- Register the PDS COM object with Project Server 2003. To do
this, follow these steps.
Note To work as expected, a .NET PDS extension must the following
requirements:
- Have the correct XmlRequestEx() or XmlRequestEx() signature.
- Have the correct class and method level attributes for
COM Interop. The GUID must be unique for each extension class. The assembly
must be strongly named but does not have to be put in the global assembly cache
(GAC). However, you can put the assembly in the GAC. To do this, follow these
steps:
- On the Project Server 2003 computer, click
Start, click Run, type
assembly in the Open box, and then
click OK.
Note The C:\Windows\assembly folder will open. - Click Start, click
Accessories, and then click Windows
Explorer.
- Locate your assembly.dll file, right-click the
assembly.dll file, and then click Copy.
- In the C:\Windows\assembly window, right-click, and
then click Paste.
Note You will see the Global Assembly Name, the Version, the Public
Key Token, and other values of the assembly that were specified.
- To install a .NET PDS extension, follow these steps:
- Click Start, click
Run, type iisreset /STOP in the
Open box, and then click OK.
- Copy the .dll extension module file to a binary
folder.
Note We recommended that %PROGRAM%BIN be
used as the binary folder. The placeholder %PROGRAM%
is the Project Server folder. Typically, the C:\Program Files\Microsoft Office
Project Server 2003\ folder is the %PROGRAM% Project
Server folder. - Repeat step b for any additional assemblies.
- Click Start, click
Run, type command in the
Open box, and then click OK.
- Type RegAsm "%PROGRAM%BIN\PdsExtension.dll"
/codebase, and then press the ENTER key.
Note RegAsm adds information about the class to the system registry so
that COM clients can use the .NET class transparently. The
/codebase option creates a Codebase entry in the registry.
This specifies the file path for an assembly that is not installed in the
global assembly cache. This is the reason why the assembly must be strongly
named. Repeat step e for any other assemblies that contain classes that are
going to be registered as PDS extensions. - Run the PdsRegister tool. This creates the required
registry entry to register the PDS extension with the Project Server PDS. To do
this, use the following syntax:
PdsRegister
Microsoft.ProjectServer.Extension.General
Note The PdsRegister tool is available for download. To download the
PdsRegister tool, visit the following Microsoft Web site:
Note Installation of the PdsRegister tool may involve other scripts
such as creating SQL Server tables, views, and stored procedures. We recommend
that all installation steps are scripted.
Additionally, the
PdsRegister tool just automates the process that is listed in the "How to
manually register the PDS extender" section.
Visual Basic 6 will
register a PDS extension automatically during compile. For more information,
visit the following Microsoft Web site:
How to manually register the PDS extenderIf you must register the PDS extender as a COM object manually,
use follow these steps. Warning If you use Registry Editor incorrectly, you may cause serious
problems that may require you to reinstall your operating system. Microsoft
cannot guarantee that you can solve problems that result from using Registry
Editor incorrectly. Use Registry Editor at your own risk. - Click Start, click Run,
type command in the Open box, and then
click OK.
- Locate and then change your path of the folder that
contains the ProjectManager.dll file.
- Type REGSVR32 ProjectManager.dll,
and then press the ENTER key.
Note This command registers the component with a ProgID of
ProjectManager.Class1. - To register the PDS extender with Project Server 2003, you
must modify the registry.
- Click Start, click Run,
type regedit in the Open box, and then
click OK.
- Locate and then right-click the following registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\11.0\MS Project\WebClient Server\ProjectServer - Point to New, and then click
String Value.
- Type
PDSExtension#, and then press
the ENTER key.
Note Where # is a number that is not
already being used. An example is PDSExtension1. The number can be any integer
value from 1 to 100. - Right-click PDSExtension1, click
Modify, type
ProjectManager.Class#, and
then click OK.
Note Where # is a number that is not
already being used. An example is ProjectManager.Class1. The number can be any
integer value from 1 to 100.
If you modify and replace an existing PDS Extender on the
Microsoft Project Server computer, you must restart Internet Services to
overwrite the .dll file. Microsoft
has confirmed that this is a problem in the Microsoft products that are listed
in the "Applies to" section. To see additional information about how to install and
register the Project Renamer PDS Extender, visit the following Web site: Visit the Project Server 2003 SDK for information about
how to build custom PDS extensions. For more information, visit the following
Web sites:
APPLIES TO- Microsoft Office Project Server 2003
| kbprogramming kbsetup kbtshoot kbprb KB867742 |
Community Feedback System
Very often, it takes hours to solve a problem. Very often, you've looked high
and low, and have tried a lot of solutions. When you finally found it, chances
are, it was because someone else helped you. Here's your chance to give back.
Use our community feedback tool to let others know what worked for you and what
didn't.
Please also understand that the community feedback system is not warranted to be
correct, it's simply a system that we've built to let people try and help each
other. If something in a feedback response doesn't make sense to you, or you're
not comfortable making changes that the feedback talks about (like registry
edits), please consult a professional.
Thank you for using kbAlertz.com Feedback System.
-- Scott Cate
|
 |
 |
 |
 |
 |
 |
 |
| |