CARVIEW |
Writing Excel Macros with VBA, Second Edition
Writing Excel Macros with VBA, 2E PDF
- By
- Steven Roman, PhD
- Publisher:
- O'Reilly Media
- Released:
- June 2002
- Pages:
- 576
Product Editions
- Writing Excel Macros with VBA, Second Edition - June 2002
- Writing Excel Macros - May 1999 (out of print)
- The Visual Basic Editor and the Excel VBA programming environment. Excel features a complete, state-of-the-art integrated development environment for writing, running, testing, and debugging VBA macros.
-
Chapter 1 Introduction
-
Selecting Special Cells
-
Setting a Chart's Data Point Labels
-
Topics in Learning Excel Programming
-
-
The VBA Environment
-
Chapter 2 Preliminaries
- What Is a Programming Language?
- Programming Style
-
Chapter 3 The Visual Basic Editor, Part I
- The Project Window
- The Properties Window
- The Code Window
- The Immediate Window
- Arranging Windows
-
Chapter 4 The Visual Basic Editor, Part II
- Navigating the IDE
- Getting Help
- Creating a Procedure
- Run Time, Design Time, and Break Mode
- Errors
- Debugging
- Macros
-
-
The VBA Programming Language
-
Chapter 5 Variables, Data Types, and Constants
- Comments
- Line Continuation
- Constants
- Variables and Data Types
- VBA Operators
-
Chapter 6 Functions and Subroutines
- Calling Functions
- Calling Subroutines
- Parameters and Arguments
- Exiting a Procedure
- Public and Private Procedures
- Project References
-
Chapter 7 Built-in Functions and Statements
- The MsgBox Function
- The InputBox Function
- VBA String Functions
- Miscellaneous Functions and Statements
- Handling Errors in Code
-
Chapter 8 Control Statements
- The If...Then Statement
- The For Loop
- The For Each Loop
- The Do Loop
- The Select Case Statement
- A Final Note on VBA
-
-
Excel Applications and the Excel Object Model
-
Chapter 9 Object Models
- Objects, Properties, and Methods
- Collection Objects
- Object Model Hierarchies
- Object Model Syntax
- Object Variables
-
Chapter 10 Excel Applications
- Providing Access to an Application's Features
- Where to Store an Application
- An Example Add-In
-
Chapter 11 Excel Events
- The EnableEvents Property
- Events and the Excel Object Model
- Accessing an Event Procedure
- Worksheet Events
- WorkBook Events
- Chart Events
- Application Events
- QueryTable Refresh Events
-
Chapter 12 Custom Menus and Toolbars
- Menus and Toolbars: An Overview
- The CommandBars Collection
- Creating a New Menu Bar or Toolbar
- Command-Bar Controls
- Built-in Command-Bar-Control IDs
- Example: Creating a Menu
- Example: Creating a Toolbar
- Example: Adding an Item to an Existing Menu
- Augmenting the SRXUtils Application
-
Chapter 13 Built-In Dialog Boxes
- The Show Method
-
Chapter 14 Custom Dialog Boxes
- What Is a UserForm Object?
- Creating a UserForm Object
- ActiveX Controls
- Adding UserForm Code
- Excel's Standard Controls
- Example: The ActivateSheet Utility
- ActiveX Controls on Worksheets
-
Chapter 15 The Excel Object Model
- A Perspective on the Excel Object Model
- Excel Enums
- The VBA Object Browser
-
Chapter 16 The Application Object
- Properties and Methods of the Application Object
- Children of the Application Object
-
Chapter 17 The Workbook Object
- The Workbooks Collection
- The Workbook Object
- Children of the Workbook Object
- Example: Sorting Sheets in a Workbook
-
Chapter 18 The Worksheet Object
- Properties and Methods of the Worksheet Object
- Children of the Worksheet Object
- Protection in Excel XP
- Example: Printing Sheets
-
Chapter 19 The Range Object
- The Range Object as a Collection
- Defining a Range Object
- Additional Members of the Range Object
- Children of the Range Object
- Example: Getting the Used Range
- Example: Selecting Special Cells
-
Chapter 20 Pivot Tables
- Pivot Tables
- The PivotTable Wizard
- The PivotTableWizard Method
- The PivotTable Object
- Properties and Methods of the PivotTable Object
- Children of the PivotTable Object
- The PivotField Object
- The PivotCache Object
- The PivotItem Object
- PivotCell and PivotItemList Objects
- Calculated Items and Calculated Fields
- Example: Printing Pivot Tables
-
Chapter 21 The Chart Object
- Chart Objects and ChartObject Objects
- Creating a Chart
- Chart Types
- Children of the Chart Object
- The Axes Collection
- The Axis Object
- The ChartArea Object
- The ChartGroup Object
- The ChartTitle Object
- The DataTable Object
- The Floor Object
- The Legend Object
- The PageSetup Object
- The PlotArea Object
- The Series Object
- Properties and Methods of the Chart Object
- Example: Scrolling Through Chart Types
- Example: Printing Embedded Charts
- Example: Setting Data Series Labels
-
Chapter 22 Smart Tags
- What Are Smart Tags?
- SmartTagRecognizer Object
- SmartTag Object
- SmartTagAction Object
- SmartTagOptions Object
-
-
Appendixes
-
Appendix A The Shape Object
- What Is the Shape Object?
- Z-Order
- Creating Shapes
- Diagram, DiagramNode, and DiagramNodeChildren Objects
-
Appendix B Getting the Installed Printers
-
Appendix C Command Bar Controls
- Built-in Command-Bar Controls
-
Appendix D Face IDs
-
Appendix E Programming Excelfrom Another Application
- Setting a Reference to the Excel Object Model
- Getting a Reference to the Excel Application Object
-
Appendix F High-Level and Low-Level Languages
- BASIC
- Visual Basic
- C and C++
- Visual C++
- Pascal
- FORTRAN
- COBOL
- LISP
-
Appendix G New Objects in Excel XP
-
-
Colophon

- Title:
- Writing Excel Macros with VBA, Second Edition
- By:
- Steven Roman, PhD
- Publisher:
- O'Reilly Media
- Formats:
-
- Ebook
- Safari Books Online
- Print Release:
- June 2002
- Ebook Release:
- December 2008
- Pages:
- 576
- Print ISBN:
- 978-0-596-00359-3
- | ISBN 10:
- 0-596-00359-5
- Ebook ISBN:
- 978-0-596-15946-7
- | ISBN 10:
- 0-596-15946-3
Our look is the result of reader comments, our own experimentation, and feedback from distribution channels. Distinctive covers complement our distinctive approach to technical topics, breathing personality and life into potentially dry subjects. The animal on the cover of Writing Excel Macros with VBA, Second Edition, is a blue jay (Cyanocitta cristata), a vociferous, aggressive bird common in the eastern half of the United States and southern Canada. The blue-crested jay is also an agile flyer and occasional nest-robber. The term "blue jay" is also applied to the Steller's jay (Cyanocitta stelleri), a larger, darker jay common in much of the western U.S. and Canada, as well as several other species.
Blue jays eat primarily nuts, seeds, and insects, sometimes planting acorns in the ground, thus helping tree growth. Known for their loud, harsh, and easily identifiable calls, blue jays (related to crows and ravens) often spoil the hunting forays of other animals by warning potential prey.
Blue jays are bright blue, white, and black, with both sexes similar in appearance. They are about 10 to 12 inches in length, and build large tree nests about 25 feet off the ground, into which are laid 3 to 6 spotted olive-colored eggs. The male is very attentive during the nesting periods. Jays are sociable and frequently travel in groups, ranging from a mating pair to a larger flock. Catherine Morris was the production editor and Tatiana Apandi Diaz was the proofreader for Writing Excel Macros with VBA, Second Edition. Darren Kelly and Claire Cloutier provided quality control. Joe Wizda wrote the index. Interior composition was done by Sarah Sherman and Catherine Morris.
Hanna Dyer designed the cover of this book, based on a series design by Edie Freedman. The cover image is a 19th-century engraving from the Dover Pictorial Archive. Emma Colby produced the cover layout with QuarkXPress 4.1 using Adobe's ITC Garamond font.
David Futato designed the interior layout. This book was converted to FrameMaker 5.5.6 with a format conversion tool created by Erik Ray, Jason McIntosh, Neil Walls, and Mike Sierra that uses Perl and XML technologies. The text font is Linotype Birka; the heading font is Adobe Myriad Condensed; and the code font is LucasFont's TheSans Mono Condensed. The illustrations that appear in the book were produced by Robert Romano and Jessamyn Read using Macromedia FreeHand 9 and Adobe Photoshop 6. The tip and warning icons were drawn by Christopher Bing. This colophon was written by Nancy Kotary.
![]() ©2009, O'Reilly Media, Inc. (707) 827-7000 / (800) 998-9938 All trademarks and registered trademarks appearing on oreilly.com are the property of their respective owners. |
About O'Reilly
Academic Solutions Authors Contacts Customer Service Jobs Newsletters O'Reilly Labs Press Room Privacy Policy RSS Feeds Terms of Service User Groups Writing for O'Reilly |
Content Archive Business Technology Computer Technology Microsoft Mobile Network Operating System Digital Photography Programming Software Web Web Design |
More O'Reilly Sites
O'Reilly Radar Ignite Tools of Change for Publishing Digital Media Inside iPhone makezine.com craftzine.com hackszine.com perl.com xml.com Partner Sites InsideRIA java.net O'Reilly Insights on Forbes.com |