Adobe COLDFUSION 9 Manual page 1183

Developing applications
Hide thumbs Also See for COLDFUSION 9:
Table of Contents

Advertisement

DEVELOPING COLDFUSION 9 APPLICATIONS
Using Web Elements and External Objects
Error
Error Diagnostic Information
Error trying to create object specified in the tag.
COM error 0x800401F3. Invalid class string.
Error Diagnostic Information
Error trying to create object specified in the tag.
COM error 0x80040154. Class not registered.
Error Diagnostic Information
Failed attempting to find "SOMEMETHOD" property/method on the
object COM error 0x80020006.
Unknown name.
Accessing Complex COM Objects using Java proxies
ColdFusion supports Java proxies to access COM objects. If you do not create Java proxies in advance, ColdFusion
must dynamically discover the COM interface. This technique can have two disadvantages:
• Dynamic discovery takes time and can reduce server performance with frequently used complex COM objects.
• Dynamic discovery uses the IDispatcher interface to determine the COM object features, and does not always
handle some complex COM interfaces.
To overcome these problems, ColdFusion includes a utility, com2java.exe, that creates static Java stub proxy classes
for COM objects. ColdFusion can use these Java stubs to access COM objects more efficiently than when it creates the
proxies dynamically. Additionally, the com2java.exe utility can create stubs for features that the dynamic proxy
generator could miss.
ColdFusion ships with pregenerated stubs for the Windows XP, Windows 2000, and Windows 97 editions of Microsoft
Excel, Microsoft Word, and Microsoft Access. ColdFusion is configured to automatically use these stubs.
If you create Java stub files for a COM object, you continue to use the
or the
function with a first argument of
CreateObject
normally do for COM objects in ColdFusion.
Use the following steps to use the com2java.exe utility. This procedure uses Microsoft Outlook as an example.
To create Java stub files for COM objects:
Configure your system as follows:
1
Ensure that a JDK (Java Development Kit) is correctly installed, including proper configuration of the
a
CLASSPATH and the command prompt PATH variable.
Add CF_root\lib\jintegra.jar to your CLASSPATH.
b
2
Make a new directory for the Java stub files; for example:
mkdir C:\src\outlookXP
This directory can be temporary. You add files from the directory to a ColdFusion JAR file.
Cause
The COM object is not registered or does not exist.
The COM object is not registered or does not exist. This error usually
occurs when an object existed previously, but was removed.
The COM object was instantiated correctly, but the method you
specified does not exist.
cfobject
, and you access the object properties and methods as you
COM
Last updated 8/5/2010
tag with a
attribute value of
type
1178
,
COM

Advertisement

Table of Contents
loading

Table of Contents