Article ID: 308937 - View products that this article applies to.
This article was previously published under Q308937
This article has been archived. It is offered "as is" and will no longer be updated.
ActiveX Document containers that use the IPrint interface to print an embedded Word document may generate one of the following error messages when calling the IPrint::Print method:
Word 2002 accidentally deletes the DVTARGETDEVICE* parameter that is passed to the IPrint::Print method. For out-of-process clients, this causes the proxy/stub code to fail on the return of the function because it tries to marshal the structure data back to the client. Although the proxy/stub DLL traps the access violation, it does not return any of the other return values to the method call and then issues the HRESULT error.
In-process callers to the method do not see this error, but the pointer that is passed to the Print method is no longer valid, and these clients may see their own access violation issues as a result.
Service Pack InformationThis problem is corrected in Office XP Service Pack 3.To resolve this problem, obtain the latest service pack for Microsoft Office XP. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
(http://support.microsoft.com/kb/307841/ )How to obtain the latest Office XP Service Pack
Hotfix InformationA supported hotfix is available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem.
If the hotfix is available for download, there is a "Hotfix download available" section at the top of this Knowledge Base article. If this section does not appear, submit a request to Microsoft Customer Service and Support to obtain the hotfix.
Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific hotfix. For a complete list of Microsoft Customer Service and Support telephone numbers or to create a separate service request, visit the following Microsoft Web site:
http://support.microsoft.com/contactus/?ws=supportNote The "Hotfix download available" form displays the languages for which the hotfix is available. If you do not see your language, it is because a hotfix is not available for that language.
After the hotfix is installed, the English version of this fix will have the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel. Date Time Size File name -------------------------------------------- 30-Apr-2003 20:12 1,804 Hotfix.txt 29-Apr-2003 06:32 6,500 Readme.txt 29-Apr-2003 07:26 8,295,812 Winwordff.msp 29-Apr-2003 06:17 3,025,704 Winwordop.msp
The English version of this fix should have the following file attributes or later: Date Time Version Size File name ---------------------------------------------------------- 28-Apr-2003 21:27 10.0.5222.0 10,603,080 Winword.exe
Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article. This problem was first corrected in Office XP Service Pack 3.
If you have to maintain compatibility with all versions of Word 2002 and cannot rely on the fix, you may be able to work around the problem. To do this, pass NULL for the DVTARGETDEVICE* parameter. In this situation, Word uses the default printer of the user as the target device. Because there is no information to marshal for the structure, the error does not occur.
If you have to specify a non-default printer before calling IPrint::Print, follow these steps:
Steps to Reproduce the ProblemNote To reproduce the problem, you must have one of the following: