package xidian.sl.netcredit.util; /** * Copyright (C) 2009-2010 Yichuan, Fuchun All rights reserved. * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this wo
源数据是A1:G18,需求是在K列显示A1:A18中各单元格重复出现的次数.在L列中是用countif函数直接计算的, Private Sub test() Dim rng As Range, i As Integer i = For Each rng In Range("A1:A18") Range("I" & i) = Application.WorksheetFunction.CountIf(Range("A" & i &a