Customer Service | Training | Contact Us
Welcome!
Login
Search Options   products areas display

Which products should be considered?

All Products

ArcCAD
ArcEditor
ArcExplorer
ArcGIS Engine
ArcGIS Explorer
ArcGIS Image Server
ArcGIS Mobile
ArcGIS Server
ArcIMS
ArcInfo Desktop
ArcInfo Workstation
ArcLogistics Route
ArcPad
ArcPad Application Builder
ArcReader
ArcSDE
ArcView
ArcView 3.x
ArcWeb Services APIs
ArcWeb Toolbar for ArcGIS
Atlas GIS
BusinessMap
BusinessMap Pro
GIS Portal Toolkit
Job Tracking for ArcGIS
MapIt
Maplex
MapObjects -- Java
MapObjects -- Windows
MapObjects IMS
MapObjects LT
MapStudio
Military Overlay Editor
NetEngine
PC ARC/INFO & DAK
PLTS
RouteMap
RouteMap IMS
SDE
Tracking Server

    Remember these settings for each visit More info
You are here:

Technical Article   Problem:  ArcMap closes when using VBA to specify IArcPressPrinter::Driver

Article ID: 19034
Bug Id: CQ00143040
Software:  ArcGIS - ArcEditor 8.1 ArcGIS - ArcInfo 8.1 ArcGIS - ArcView 8.1
Platforms:  Windows NT 4.0, 2000

Description

ArcMap will crash when using Visual Basic for Applications (VBA) code to specify a driver on the IArcPressPrinter interface.

Cause

The IPrinter::Paper object was not set up correctly.

Solution or Workaround

This problem is addressed in ArcGIS 8.1.2.

The following code snippet demonstrates how to set up the IPrinter::Paper object before specifying a driver.

Dim pApp as IApplication

Set pApp = Application

Dim pMxApp as IMxApplication
Set pMxApp = pApp

Dim pPrinter as IPrinter
Set pPrinter = New ArcPressPrinter

Dim pArcPressPrinter as IArcPressPrinter
Set pArcPressPrinter = pPrinter

Set pPrinter.Paper = pMxApp.Paper

pArcPressPrinter.Driver = <member of esriArcPressDriverPrinters>



Created: 5/9/2001
Last Modified: 9/22/2003

This website's graphical display is now viewable only with W3C standards-compliant browsers, but the content is accessible to all browsers and Internet devices. View our supported browser matrix for more information on our website display.