Excel Visual Basic Variables, Part 2: Declaring and Naming Variables, Scope and Lifetime
Subscribe to continue reading
Subscribe to get access to the rest of this post and other subscriber-only content.
Subscribe to get access to the rest of this post and other subscriber-only content.
The Excel Visual Basic Editor can be set to appear in a variety of ways. In the appearance shown below (the default) the majority of windows appear docked at one edge of the screen. Code windows can be tiled together on the screen, or one can be maximized. The main features of the screen are…
We had an earlier post, How to Use Objects, Collections, Properties, Events and Methods in Excel Visual Basic. There, we introduced the idea of Objects and Collections. We listed the most useful Objects, and Collections of Objects. Below we have more extensive diagrams, specifically for the Excel Object Model. It helps to understand the hierarchy:…
The easiest way to create a macro is: The instructions below are for Excel. Word is similar, but has its own quirks (and no “Absolute or Relative”). If you want to look at programming basics first, see this previous post. 1. Recording a Macro Absolute or Relative What does that mean? When you record Absolute,…
This is an excerpt from Microsoft Excel 2000 Visual Basic Help. 1. Objects and Collections An object represents an element of an application, such as a worksheet, a cell, a chart, a form, or a report. In Visual Basic code, you must first identify an object. Only then can you apply one of the object’s…
A Macro is a computer program that can duplicate actions you take in a spreadsheet. Macros perform key tasks faster. They can have a short-cut key combination to run them easily. Creating Excel and Word Macros is easier than most other methods of programming. You simply record the actions you took in the program. You…