ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

[µo°Ý] ¢×¢Ô¡@¦h±ø¥ó§PÂ_¦p¦ó§ï¬°°}¦C°õ¦æ¡U

[µo°Ý] ¢×¢Ô¡@¦h±ø¥ó§PÂ_¦p¦ó§ï¬°°}¦C°õ¦æ¡U

¥»©«³Ì«á¥Ñ starry1314 ©ó 2015-10-12 09:33 ½s¿è

¥\¯à¡G¢ÒÄ椺¡@¤£¬°¡i¢Ú¡C¢Þ¡C¢â¡C¢ß¡C¢×¡j¤@«ß¨ú¥N¬°¢Ï
½Ð°Ý¦p¦ó§ï¬°¥H°}¦C¼Ò¦¡°õ¦æ©O¡H¡@¦]´NºâÃö³¬¿Ã¹õ¨ê·s»P¦Û°Ê­pºâ¡AÁÙ¬O¦³ÂIºC
  1. Sub ¥N¸¹´À´«()

  2. For I = 2 To 50000
  3. £P = Range("d" & I)
  4. If £P <> "L" And £P <> "P" And £P <> "T" And £P <> "Q" And £P <> "I" Then
  5. Range("D" & I) = "A"
  6. End If
  7. Next
  8. End Sub
½Æ»s¥N½X

¦^´_ 1# starry1314


    §A­nªº°}¦C¼Ò¦¡³o³o¼Ë¶Ü¡H
  1. Sub ¥N¸¹´À´«()
  2. Dim Arr(1 To 49999, 1 To 1)
  3. For I = 2 To 50000
  4. £P = Range("d" & I)
  5. If £P <> "L" And £P <> "P" And £P <> "T" And £P <> "Q" And £P <> "I" Then
  6.     Arr(I - 1, 1) = "A"
  7. Else
  8.     Arr(I - 1, 1) = Range("d" & I)
  9. End If
  10. Next
  11. [d2].Resize(UBound(Arr)) = Arr
  12. End Sub
½Æ»s¥N½X

TOP

¦^´_ 1# starry1314

³o¼Ë¤]¦æ
  1. Sub ¥N¸¹´À´«1()
  2. Dim Rng As Range
  3. Dim arr
  4. ro = Cells(Rows.Count, 4).End(xlUp).Row
  5. ReDim arr(1 To ro, 1 To 1)
  6. For Each Rng In Range("d2:D" & ro)
  7. i = i + 1
  8. £P = Rng.Value
  9. If £P <> "L" And £P <> "P" And £P <> "T" And £P <> "Q" And £P <> "I" Then
  10.     arr(i, 1) = "A"
  11. Else
  12.     arr(i, 1) = Rng.Value
  13. End If
  14. Next
  15. [d2].Resize(UBound(arr)) = arr
  16. End Sub
½Æ»s¥N½X

TOP

Sub AA1012_1()
Dim Arr, i&
With Range([D2], Cells(Rows.Count, "D").End(xlUp))
¡@¡@¡@Arr = .Value
¡@¡@¡@For i = 1 To .Count
¡@¡@¡@¡@¡@If InStr("LPTQI", Arr(i, 1)) = 0 Then Arr(i, 1) = "A"
¡@¡@¡@Next i
¡@¡@¡@.Value = Arr
End With
End Sub

TOP

¦^´_ 4# ­ã´£³¡ªL

ÁÂÁª©¤j ¨Ó¸Ô²Ó¤F¸Ñ¤U InStr

TOP

¦^´_ 3# lpk187
ÁÂÁÂ~¬Oªº ¨Ó¸Õ¸Õ¬Ý

TOP

        ÀR«ä¦Û¦b : ¸Ü¦h¤£¦p¸Ü¤Ö¡A¸Ü¤Ö¤£¦p¸Ü¦n¡C
ªð¦^¦Cªí ¤W¤@¥DÃD