The Immediate window

The Immediate window provides an opportunity to enter a line of code that will execute immediately. It is displayed by default the first time you open the Debug window, otherwise to display it, select View > Immediate Window or press [Crtl] + [G]. The Immediate window provides an ideal tool for experimentation; for the result of any command entered is immediately interpreted. In the example shown in Figure 8.8, the effect of the command: ActiveCell.Value = 4 can be seen to be entered immediately in the ActiveCell shown (i.e. C17) This is useful because the Excel Output window can be tiled with the Immediate window.

S Mirriisort Cücel - SALESMAN

File Edit View Insert Format lools Data Window Help

JSjxJ

S Mirriisort Cücel - SALESMAN

File Edit View Insert Format lools Data Window Help

JSjxJ

ïJsS Q B 5} t Arial

- ICI - B I

U W-

9 mm

g? %

iw

- A -

»

A

B m

D

E

F

■a.

H

1

.J

6

él

7

8

s

■'I

IG

4

11

12

n

14

Result of Activecell available

15

16

immediately in worksheet

17

IB

/

1 1 1 1

19

/

S

M 1

^ n \ Sht

et2 \sheetl / wsekjysales 7 wee

sales test

data /.Sur

-imary | í

_i >ir

USfc / //.

act ivece11.Value=4

The immediate window act ivece11.Value=4

The immediate window iT

Figure 8.8 Using the Immediate window

0 0

Post a comment