The Drosophila middle midgut cells derived from the endoderm develop into four distinct types of cell. Of these cells, copper cells have invaginated microvillar membranes on their apical surface, and they are involved in two distinct functions, i.e., copper absorption and acid secretion. The homeobox gene defective proventriculus (dve) is expressed in the midgut, and two transcripts, type A (∼4.9kb) and type B (∼3.5kb), have been identified. We isolated the deletion allele dve(E181) that completely removes the first exon for type-A (dve-A) transcript. Dve expression pattern in dve-A mutant background indicates that isoform switching is dynamically regulated in a cell-type specific manner. Using RNAi for dve-A, we examined spatial and temporal requirement of the Dve-A activity. Early Dve-A activity is required to repress isoform switching in copper cells, and for establishment of two gut functions. Late Dve-A activity in copper cells, but not in adjacent interstitial cells, is required for acid secretion, while the activity is redundantly required in both cells for the copper absorptive function. Furthermore, ectopic type-B expression in larval copper cells specifically impaired the copper absorptive function. These results provide insight into molecular mechanisms to establish functional specificity.