The integral quantum Hall effect can be explained either as resulting from bulk or edge currents (or, as it occurs in real samples, as a combination of both). This leads to different definitions of Hall conductance, which agree under appropriate hypotheses, as shown by Schulz-Baldes et al. by means of K-theory. We propose an alternative proof based on a generalization of the index of a pair of projections to more general operators. The equality of conductances is an expression of the stability of that index as a flux tube is moved from within the bulk across the boundary of a sample. The model and the result The simultaneous quantization of bulk and edge conductance is essential to the QHE in finite samples, as explained in [8, 13]. In these two references that property is established in the context of an effective field theory description, resp. of a microscopic treatment suitable to the integral QHE. The present paper is placed in the latter setting as well. In our model H is a discrete Schrödinger operator on the single-particle Hilbert space l2(Z×N) over the upper half-plane. It is obtained from the restriction (with e.g. Dirichlet boundary conditions) of a ‘bulk’ Hamiltonian HB acting on l 2(Z×Z). These assumptions are spelled out in detail at the end of this section. The spectrum of HB (but not that of H , as a rule) has an open gap ∆ containing the Fermi energy: ∆ ∩ σ(HB) = ∅ . (1) Let PB be the Fermi projection: PB = E(−∞,μ](HB) for any μ ∈ ∆. A real-valued function g ∈ C(R) with g(λ) = 1 (resp. 0) for λ large and negative (resp. positive) will be called a switch function. We remark that PB = g(HB) if the switch function has supp g ⊂ ∆.