C


Calculate method, 71

cancel buttons on user forms, 314–315

canceling events, 279–280

cell styles

built-in, 132

modifying, 133

cells

Currency format, applying, 5–7

formatting, with built-in tool, 5

formatting, with macro, 6–7

Cells method, 126

Cells property, 98–100

selecting all cells with, 98

selecting specific cells with, 99

cells, table

merging and centering. see Merge And

Center button

referencing, 152

cells, worksheet

formulas, inserting in all selected, 49

gradient fills. see gradient fills

properties for, 122

referencing by number, 99

referencing by row and column, 99–100

referencing, difference in Excel 2007, 100

relative references vs. absolute

references, 58–60

selecting all, 101

selecting blank, 48–49

style, assigning to. see cell styles

Chart object, 203

chart objects

accessing without selecting, 203

axes, fixed, 204

creating, 201–202

defined, 201

formatting, 207

gradient fills, applying to elements of, 206

naming, 203

synchronizing, 203–205

type, selecting, 202

ChDir statement, 43

check boxes

adding to forms, 309

captioning, 309

defined, 309

event handlers for, 310

implementing, 327–328

sizing, 309

clearing formatting from worksheets, 134

Click event, 310

CLng function, 241

Close method, 78

closing

databases, 60

workbooks, without saving changes, 83

code name for worksheets, 183

collections

adding items to. see Add method

Array function unavailable for, 89

ColorStops, 180

CustomViews, 320

defined, 68

GradientStops, 184

items in, vs. instances, 81

looping through, 220–222

naming items in, 81–82

properties of, 70

referencing specific items in, 79–81, 81–82, 197

subcollections for. see subcollections

colon-equal signs in macros, 27

colors

setting, 131–135

specifying, 131

ColorStops collection, 180

columns, PivotTable

autofitting, 166

fill color, 168

width, standardizing, 163–164

Columns property, 101–103

selecting all cells with, 101

columns, table

captioning, 150

inserting, 146

columns, worksheet

hiding dynamically, 321–325

inserting, 52

referencing by letter, 102

referencing by number, 101

referencing by range, 102

width, specifying, 177

combo boxes

column widths, setting, 296–297

event handlers, creating, 297–299

inserting, 293–294

populating lists with, 295–296

styles, 294

command buttons

aligning, 265

appearance of, 264

as cancel buttons, 314–315

captioning, 266

copying, 314

default on form, 314

design mode vs. run mode, 267–268

event handlers, adding, 315

events recognized by, 270

inserting, 265

macros, linking to, 267–268

mouse movements, responding to, 270–271

naming, 265–266

properties, displaying, 265–266

snapping to grid, 265

TakeFocusOnClick property, 266

in user forms, adding, 314–316

CommandButton button, 314

comments, 11

compiler errors, 246

Complete Word command, 104

conditional expressions

defined, 211

in Do statements, 227

for input boxes, 214–215

with MsgBox function, 219

multiple conditions in, 212–213

conditional formats, 182

confirmation dialog box, creating. see MsgBox function

controls. see also check boxes; option

buttons; scroll bars; spin buttons;

text boxes

copying, 289

initializing, 314

option buttons, checking for, 326

tab order, setting, 316–317

Copy method, 87

copying

controls, 289

worksheets, macro for, 87

Count property for Workbooks object, 77–78

CreateNames method, 125

CreatePivotTable method, 155

Currency format

vs. Accounting format, 5

applying to cells, 5–7

customizing, 6–7

current region

defined, 48

selecting, 48, 49

CurrentRegion property, 104

with multicell range as starting

point, 106

custom dialog boxes. see user forms

CustomView object, 320

CustomViews collection, 320



Microsoft Office Excel 2007 Visual Basic for Applications Step by Step
Microsoft Excel 2002 Visual Basic for Applications Step by Step (Step by Step (Microsoft))
ISBN: 0735613591
EAN: 2147483647
Year: 2004
Pages: 99
Authors: Reed Jacobsen

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net