Advertisement
Guest User

Untitled

a guest
Aug 25th, 2013
623
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.10 KB | None | 0 0
  1.  
  2. Sub test()
  3. nEnd = Cells.SpecialCells(xlCellTypeLastCell).Row
  4.  
  5. For i = 1 To nEnd
  6. Cells(i, 1) = aaa(Cells(i, 1), "jcom")
  7. Cells(i, 1) = aaa(Cells(i, 1), "docomo")
  8. Cells(i, 1) = aaa(Cells(i, 1), "softbank")
  9. Cells(i, 1) = aaa(Cells(i, 1), "biglobe")
  10. Cells(i, 1) = aaa(Cells(i, 1), "ezweb")
  11. Cells(i, 1) = aaa(Cells(i, 1), "so-net")
  12. Cells(i, 1) = aaa(Cells(i, 1), ".ocn.ne.jp")
  13. Cells(i, 1) = aaa(Cells(i, 1), "nifty")
  14. Cells(i, 1) = aaa(Cells(i, 1), ".odn.ne.jp")
  15. Cells(i, 1) = aaa(Cells(i, 1), "gmail.com")
  16. Cells(i, 1) = aaa(Cells(i, 1), ".dion.ne.jp")
  17. Cells(i, 1) = aaa(Cells(i, 1), "iij4u")
  18. Cells(i, 1) = aaa(Cells(i, 1), "hinet.net")
  19. Cells(i, 1) = aaa(Cells(i, 1), ".email.ne.jp")
  20. Cells(i, 1) = aaa(Cells(i, 1), ".eonet.ne.jp")
  21. Cells(i, 1) = aaa(Cells(i, 1), ".tiki.ne.jp")
  22. Cells(i, 1) = aaa(Cells(i, 1), "mopera.net")
  23. Cells(i, 1) = aaa(Cells(i, 1), "vodafone.ne.jp")
  24. Cells(i, 1) = aaa(Cells(i, 1), ".dti.ne.jp")
  25. Cells(i, 1) = aaa(Cells(i, 1), "@ybb.ne.jp")
  26. Cells(i, 1) = aaa(Cells(i, 1), ".pdx.ne.jp")
  27. Cells(i, 1) = aaa(Cells(i, 1), ".sakura.ne.jp")
  28. Cells(i, 1) = aaa(Cells(i, 1), ".plala.or.jp")
  29. Cells(i, 1) = aaa(Cells(i, 1), "@icloud.com")
  30. Cells(i, 1) = aaa(Cells(i, 1), "@mac.com")
  31. Cells(i, 1) = aaa(Cells(i, 1), "livedoor.com")
  32. Cells(i, 1) = aaa(Cells(i, 1), ".wakwak.com")
  33. Cells(i, 1) = aaa(Cells(i, 1), "@me.com")
  34. Cells(i, 1) = aaa(Cells(i, 1), ".zaq.ne.jp")
  35. Cells(i, 1) = aaa(Cells(i, 1), ".gyao.ne.jp")
  36. Cells(i, 1) = aaa(Cells(i, 1), "@pdx.ne.jp")
  37. Cells(i, 1) = aaa(Cells(i, 1), ".hi-ho.ne.jp")
  38. Cells(i, 1) = aaa(Cells(i, 1), "@dream.com")
  39. Cells(i, 1) = aaa(Cells(i, 1), "@outlook.com")
  40. Cells(i, 1) = aaa(Cells(i, 1), "@aol.com")
  41. Cells(i, 1) = aaa(Cells(i, 1), "@emobile.ne.jp")
  42. Cells(i, 1) = aaa(Cells(i, 1), "@willcom.com")
  43. Cells(i, 1) = aaa(Cells(i, 1), "@asahi-net.or.jp")
  44. Cells(i, 1) = aaa(Cells(i, 1), ".gyao.ne.jp")
  45. Cells(i, 1) = aaa(Cells(i, 1), "@googlemail.com")
  46. Cells(i, 1) = aaa(Cells(i, 1), ".infoweb.ne.jp")
  47. Cells(i, 1) = aaa(Cells(i, 1), ".sannet.ne.jp")
  48. Cells(i, 1) = aaa(Cells(i, 1), ".xrea.com")
  49. Cells(i, 1) = aaa(Cells(i, 1), ".interq.or.jp")
  50. Cells(i, 1) = aaa(Cells(i, 1), "@yahoo.c.o.jp")
  51. Cells(i, 1) = aaa(Cells(i, 1), "@mail.ne.jp")
  52. Cells(i, 1) = aaa(Cells(i, 1), "@mail.bbexcite.jp")
  53. Cells(i, 1) = aaa(Cells(i, 1), "@e-mail.jp")
  54. Cells(i, 1) = aaa(Cells(i, 1), "@y7mail.com")
  55. Cells(i, 1) = aaa(Cells(i, 1), "@mail.wbs.ne.jp")
  56. Cells(i, 1) = aaa(Cells(i, 1), ".bekkoame.ne.jp")
  57. Cells(i, 1) = aaa(Cells(i, 1), "@yahoo.com")
  58. Cells(i, 1) = aaa(Cells(i, 1), "@mbox.co.jp")
  59. Next
  60.  
  61. '空白行削除
  62. For i = nEnd To 1 Step -1
  63. If WorksheetFunction.CountA(Rows(i)) = 0 Then
  64. Rows(i).Delete
  65. End If
  66. Next i
  67.  
  68. End Sub
  69.  
  70.  
  71. Function aaa(strText, strFind) As String
  72.  
  73. strRet = ""
  74. If strText <> "" Then
  75. If InStr(strText, strFind) = 0 Then
  76. strRet = strText
  77. End If
  78. End If
  79. aaa = strRet
  80. End Function
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement