{"id":9564,"date":"2022-09-20T17:26:15","date_gmt":"2022-09-20T08:26:15","guid":{"rendered":"https:\/\/extan.jp\/?p=9564"},"modified":"2022-09-26T00:28:47","modified_gmt":"2022-09-25T15:28:47","slug":"%e3%80%90excel-vba%e3%80%91%e3%83%ab%e3%83%bc%e3%83%97%e3%81%a7%e3%82%bb%e3%83%ab%e3%81%ae%e5%80%a4%e3%82%92%e5%8f%96%e5%be%97%e3%81%99%e3%82%8b%e6%96%b9%e6%b3%9510%e9%81%b8%ef%bc%81","status":"publish","type":"post","link":"https:\/\/extan.jp\/?p=9564","title":{"rendered":"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01"},"content":{"rendered":"<p>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u305f\u3044\u3068\u304d\u306f\u306a\u3044\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n<p>\u3051\u3069\u3001\u305d\u3093\u306a\u4e2d\u3067\u60a9\u3080\u3053\u3068\u306f\u3001<\/p>\n<div class=\"kininarukoto1\">\u30fbVBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u305f\u3044\u304c\u65b9\u6cd5\u304c\u3088\u304f\u308f\u304b\u3089\u306a\u3044<br \/>\n\u30fbVBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u305f\u304c\u601d\u3046\u3088\u3046\u306b\u53d6\u5f97\u3067\u304d\u305a\u56f0\u3063\u3066\u3044\u308b<\/div>\n<p>\u3067\u3059\u3088\u306d\u3002<\/p>\n<p>\u4eca\u56de\u306f\u305d\u3093\u306a\u304a\u60a9\u307f\u3092\u89e3\u6c7a\u3059\u308b<\/p>\n<div class=\"rdinfo\">\u30fbVBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\u3068\u30b5\u30f3\u30d7\u30eb\u8868\u3092\u4f7f\u3063\u305f\u9069\u7528\u4f8b<\/div>\n<p>\u306b\u3064\u3044\u3066\u307e\u3068\u3081\u307e\u3059\uff01<\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_66_1 counter-hierarchy ez-toc-counter ez-toc-light-blue ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\"><p class=\"ez-toc-title\">\u3082\u304f\u3058<\/p>\n<\/div><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E3%82%A4%E3%83%A1%E3%83%BC%E3%82%B8\" title=\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u30a4\u30e1\u30fc\u30b8\">VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u30a4\u30e1\u30fc\u30b8<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A0%EF%BC%9AFor%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\" title=\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2460\uff1aFor&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\">VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2460\uff1aFor&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/extan.jp\/?p=9564\/#%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E8%A1%A8%E3%82%92%E6%BA%96%E5%82%99%E3%81%99%E3%82%8B\" title=\"\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u8868\u3092\u6e96\u5099\u3059\u308b\">\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u8868\u3092\u6e96\u5099\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/extan.jp\/?p=9564\/#For%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\" title=\"For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\">For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/extan.jp\/?p=9564\/#For%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A0a\" title=\"For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2460a\">For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2460a<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E5%AE%9F%E8%A3%85\" title=\"VBA\u306e\u5b9f\u88c5\">VBA\u306e\u5b9f\u88c5<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/extan.jp\/?p=9564\/#For%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A0b\" title=\"For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2460b\">For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2460b<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-2\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-12\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-2\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-13\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-2\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-14\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A1%EF%BC%9AFor_Each%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\" title=\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2461\uff1aFor Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\">VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2461\uff1aFor Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-15\" href=\"https:\/\/extan.jp\/?p=9564\/#For_Each%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\" title=\"For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\">For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-16\" href=\"https:\/\/extan.jp\/?p=9564\/#For_Each%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A1a\" title=\"For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2461a\">For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2461a<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-17\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-3\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-18\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-3\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-19\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-3\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-20\" href=\"https:\/\/extan.jp\/?p=9564\/#For_Each%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A1b\" title=\"For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2461b\">For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2461b<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-21\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-4\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-22\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-4\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-23\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-4\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-24\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A2%EF%BC%9AWhile%E2%80%A6Wend_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\" title=\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2462\uff1aWhile&#8230;Wend \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\">VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2462\uff1aWhile&#8230;Wend \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-25\" href=\"https:\/\/extan.jp\/?p=9564\/#While%E2%80%A6Wend%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\" title=\"While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\">While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-26\" href=\"https:\/\/extan.jp\/?p=9564\/#While%E2%80%A6Wend%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A2a\" title=\"While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2462a\">While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2462a<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-27\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-5\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-28\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-5\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-29\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-5\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-30\" href=\"https:\/\/extan.jp\/?p=9564\/#While%E2%80%A6Wend%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A2b\" title=\"While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2462b\">While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2462b<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-31\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-6\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-32\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-6\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-33\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-6\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-34\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A3%EF%BC%9ADo_While%E2%80%A6Loop_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\" title=\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2463\uff1aDo While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\">VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2463\uff1aDo While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-35\" href=\"https:\/\/extan.jp\/?p=9564\/#Do_While%E2%80%A6Loop_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\" title=\"Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\">Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-36\" href=\"https:\/\/extan.jp\/?p=9564\/#Do_While%E2%80%A6Loop_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A3a\" title=\"Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2463a\">Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2463a<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-37\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-7\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-38\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-7\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-39\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-7\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-40\" href=\"https:\/\/extan.jp\/?p=9564\/#Do_While%E2%80%A6Loop_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A3b\" title=\"Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2463b\">Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2463b<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-41\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-8\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-42\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-8\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-43\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-8\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-44\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A4%EF%BC%9ADo%E2%80%A6Loop_While_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\" title=\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2464\uff1aDo&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\">VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2464\uff1aDo&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-45\" href=\"https:\/\/extan.jp\/?p=9564\/#Do%E2%80%A6Loop_While_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\" title=\"Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\">Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-46\" href=\"https:\/\/extan.jp\/?p=9564\/#Do%E2%80%A6Loop_While_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A4a\" title=\"Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2464a\">Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2464a<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-47\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-9\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-48\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-9\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-49\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-9\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-50\" href=\"https:\/\/extan.jp\/?p=9564\/#Do%E2%80%A6Loop_While_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A4b\" title=\"Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2464b\">Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2464b<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-51\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%B3%E3%83%BC%E3%83%89-10\" title=\"VBA\u30b3\u30fc\u30c9\">VBA\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-52\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-10\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-53\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E8%AA%AC%E6%98%8E-10\" title=\"VBA\u306e\u8aac\u660e\">VBA\u306e\u8aac\u660e<\/a><\/li><\/ul><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-54\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%81%AE%E5%AE%9F%E8%A3%85%E6%89%8B%E9%A0%86\" title=\"VBA\u306e\u5b9f\u88c5\u624b\u9806\">VBA\u306e\u5b9f\u88c5\u624b\u9806<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-55\" href=\"https:\/\/extan.jp\/?p=9564\/#VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-11\" title=\"VBA\u3092\u5b9f\u884c\u3059\u308b\">VBA\u3092\u5b9f\u884c\u3059\u308b<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-56\" href=\"https:\/\/extan.jp\/?p=9564\/#%E3%81%95%E3%81%84%E3%81%94%E3%81%AB\" title=\"\u3055\u3044\u3054\u306b\">\u3055\u3044\u3054\u306b<\/a><\/li><\/ul><\/nav><\/div>\n<h2><span class=\"ez-toc-section\" id=\"VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E3%82%A4%E3%83%A1%E3%83%BC%E3%82%B8\"><\/span>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u30a4\u30e1\u30fc\u30b8<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u30a4\u30e1\u30fc\u30b8\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>Excel\u5074\u306b\u8868\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002<br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-9620\" src=\"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/092222_1351_1.png\" alt=\"\" width=\"225\" height=\"214\" \/><\/p>\n<p>VBA\u3092\u5b9f\u884c\u3059\u308b\u3068\u3001\u8868\u306e\u884c\u6570\u5206\u30eb\u30fc\u30d7\u3057\u3066\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-9621\" src=\"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/092222_1351_2.png\" alt=\"\" width=\"137\" height=\"126\" \/><\/p>\n<p>\u305d\u308c\u3092\u30eb\u30fc\u30d7\u51e6\u7406\u5225\u306b\uff15\u30d1\u30bf\u30fc\u30f3\u306b\u76f4\u63a5\u30bb\u30eb\u3092\u53c2\u7167\u3059\u308b\u65b9\u5f0f\u3068\u914d\u5217\u306b\u683c\u7d0d\u3057\u3066\u51e6\u7406\u3059\u308b\u5f62\u5f0f\u305d\u308c\u305e\u308c2\u3064\u306b\u5206\u3051\u3066\u8aac\u660e\u3092\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u305d\u308c\u3067\u306f\u65e9\u901f\u8a66\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<h2><span class=\"ez-toc-section\" id=\"VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A0%EF%BC%9AFor%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\"><\/span>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2460\uff1aFor&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2460\uff1aFor&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E8%A1%A8%E3%82%92%E6%BA%96%E5%82%99%E3%81%99%E3%82%8B\"><\/span>\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u8868\u3092\u6e96\u5099\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Excel\u5074\u306b&#8221;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u4f5c\u6210\u3057\u3001\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u5bfe\u8c61\u3068\u306a\u308b\u8868\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002<br \/>\n\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u6700\u7d42\u884c\u3092\u53d6\u5f97\u3059\u308b\u5bfe\u8c61\u306e\u5217\u306fA\u5217\u3068\u306a\u308a\u307e\u3059\u3002<br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-9620\" src=\"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/092222_1351_1.png\" alt=\"\" width=\"225\" height=\"214\" \/><\/p>\n<h3><span class=\"ez-toc-section\" id=\"For%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\"><\/span>For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<div class=\"info\"><code>For counter  = start To end  step [ statements ]\n[ Exit For ]\nNext counter <\/code><\/div>\n<p>For\u2026Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306e\u6307\u5b9a\u9805\u76ee\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<table width=\"100%\">\n<tbody>\n<tr>\n<th>\u30d1\u30fc\u30c4<\/th>\n<th>\u8aac\u660e<\/th>\n<\/tr>\n<tr>\n<td>counter<\/td>\n<td>\u5fc5\u9808\u3002 \u30eb\u30fc\u30d7 \u30ab\u30a6\u30f3\u30bf\u30fc\u3068\u3057\u3066\u4f7f\u7528\u3059\u308b\u6570\u5024\u5909\u6570\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002 \u3053\u306e\u5909\u6570\u306b\u306f\u3001\u30d6\u30fc\u30eb\u5024\u307e\u305f\u306f\u914d\u5217\u8981\u7d20\u3092\u6307\u5b9a\u3067\u304d\u307e\u305b\u3093\u3002<\/td>\n<\/tr>\n<tr>\n<td>start<\/td>\n<td>\u5fc5\u9808\u3067\u3059\u3002counter\u306e\u521d\u671f\u5024\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>end<\/td>\n<td>\u5fc5\u9808\u3002counter\u306e\u6700\u7d42\u5024\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>step<\/td>\n<td>\u30aa\u30d7\u30b7\u30e7\u30f3\u3002 \u30eb\u30fc\u30d7\u3092\u7e70\u308a\u8fd4\u3059\u305f\u3073\u306b\u3001counter\u306e\u6570\u304c\u5909\u66f4\u3055\u308c\u307e\u3059\u3002 \u7701\u7565\u3055\u308c\u308b\u3068\u3001step\u306f\u65e2\u5b9a\u5024\u306e 0 \u306b\u306a\u308a\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>statements<\/td>\n<td>\u7701\u7565\u53ef\u80fd\u3002 \u6307\u5b9a\u3057\u305f\u56de\u6570\u5b9f\u884c\u3055\u308c\u308bFor\u3068Next\u306e\u9593\u306e 1 \u3064\u4ee5\u4e0a\u306e\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3002<\/td>\n<\/tr>\n<tr>\n<td>Exit For<\/td>\n<td>For \u30eb\u30fc\u30d7\u3092\u629c\u3051\u307e\u3059\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u53c2\u8003\uff1ahttps:\/\/learn.microsoft.com\/ja-jp\/office\/vba\/language\/reference\/user-interface-help\/fornext-statement<\/p>\n<p><!--\u5439\u304d\u51fa\u3057\u306f\u3058\u307e\u308a--><\/p>\n<div class=\"balloon5\">\n<div class=\"faceicon\">\n<img loading=\"lazy\" decoding=\"async\" src=\"\/wp-content\/uploads\/2020\/11\/taka_kao.gif\" alt=\"\u30bf\u30ab\u30d2\u30ed\" width=\"110\" height=\"110\" \/>\n<div class=\"faceiconfont\">\u30bf\u30ab\u30d2\u30ed<\/div>\n<\/div>\n<div class=\"chatting\">\n<div class=\"says\">For\u2026Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u4f7f\u3044\u65b9\u306b\u3064\u3044\u3066\u3088\u308a\u8a73\u7d30\u306b\u77e5\u308a\u305f\u3044\u65b9\u306f\u3053\u3061\u3089\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\u3002<br \/>\n<a href=\"https:\/\/extan.jp\/?p=9610\">\u3010Excel VBA\u3011For Next\u6587\u306e\u4f7f\u3044\u65b9\uff01\u629c\u3051\u308b\u65b9\u6cd5\u3084\u5225\u30b7\u30fc\u30c8\u8ee2\u8a18\u3082\uff01<\/a><br \/>\n<a href=\"https:\/\/extan.jp\/?p=9654\">\u3010Excel VBA\u3011\u5947\u6570\/\u5076\u6570\u3092\u5224\u5b9a\u3057\u62bd\u51fa\u3059\u308b\u65b9\u6cd5\uff01Mod\u6f14\u7b97\u5b50\u4f7f\u7528\uff01<\/a>\n<\/div>\n<\/div>\n<\/div>\n<p><!--\u5439\u304d\u51fa\u3057\u7d42\u308f\u308a--><\/p>\n<h3><span class=\"ez-toc-section\" id=\"For%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A0a\"><\/span>For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2460a<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2460a()\n    Dim intLastRowNum As Integer\n    Dim i As Integer\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n\n        For i = 2 To intLastRowNum\n            Debug.Print .Cells(i, 1).Value &amp; &quot;|&quot; &amp; .Cells(i, 2).Value &amp; &quot;|&quot; &amp; .Cells(i, 3).Value\n        Next i\n        \n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E5%AE%9F%E8%A3%85\"><\/span>VBA\u306e\u5b9f\u88c5<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306e\u5b9f\u88c5\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306f<br \/>\nVBA\u306e\u5b9f\u88c5\u624b\u9806<br \/>\n\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\u3002<\/p>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code>1|A|100<br \/>\n2|B|110<br \/>\n3|C|120<br \/>\n4|D|130<br \/>\n5|E|140<br \/>\n6|F|150<br \/>\n7|G|160<\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u30672\u884c\u76ee\u304b\u3089\u6700\u7d42\u884c\u76ee\u307e\u3067\u7e70\u308a\u8fd4\u3057\u51e6\u7406\u3092\u304a\u3053\u306a\u3044\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>For i = 2 To intLastRowNum<\/code><\/div>\n<p>Cells\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306eValue\u30d7\u30ed\u30d1\u30c6\u30a3\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u3001 &#8220;|&#8221;\u533a\u5207\u308a\u3067\u6587\u5b57\u7d50\u5408\u3092\u3057\u3066\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>Debug.Print .Cells(i, 1).Value &amp; &quot;|&quot; &amp; .Cells(i, 2).Value &amp; &quot;|&quot; &amp; .Cells(i, 3).Value<\/code><\/div>\n<h3><span class=\"ez-toc-section\" id=\"For%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A0b\"><\/span>For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2460b<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-2\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2460b()\n    Dim intLastRowNum As Integer\n    Dim arrTemp As Variant\n    Dim i As Integer\n    Dim j As Integer\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        &#039;\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002\n        arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))\n\n        For i = LBound(arrTemp, 1) To UBound(arrTemp, 1)\n        \n            For j = LBound(arrTemp, 2) To UBound(arrTemp, 2)\n            \n                Debug.Print arrTemp(i, j)\n        \n            Next j\n        Next i\n\n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-2\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code> 1<br \/>\nA<br \/>\n100<br \/>\n2<br \/>\nB<br \/>\n110<br \/>\n3<br \/>\nC<br \/>\n120<br \/>\n4<br \/>\nD<br \/>\n130<br \/>\n5<br \/>\nE<br \/>\n140<br \/>\n6<br \/>\nF<br \/>\n150<br \/>\n7<br \/>\nG<br \/>\n160 <\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-2\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))<\/code><\/div>\n<p>For&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u914d\u5217\u306e\u306f\u3058\u3081\u306e\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u304b\u3089\u6700\u7d42\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u307e\u3067\u7e70\u308a\u8fd4\u3057\u51e6\u7406\u3092\u304a\u3053\u306a\u3044\u307e\u3059\u3002<br \/>\nLbound\u95a2\u6570\u306f\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u6700\u5c0f\u5024\u3001Ubound\u95a2\u6570\u306f\u914d\u5217\u306e\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u306e\u6700\u5927\u5024\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<p>\u4e8c\u6b21\u5143\u914d\u5217\u3068\u306a\u3063\u3066\u3044\u308b\u306e\u3067\u3001Lbound\u95a2\u6570\u3001Ubound\u95a2\u6570\u306b1\u6b21\u5143\u30012\u6b21\u5143\u3092\u5f15\u6570\u306b\u6307\u5b9a\u3057\u3001\u305d\u308c\u305e\u308c\u306e\u914d\u5217\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u6570\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<div class=\"info\">\n<p><code>        For i = LBound(arrTemp, 1) To UBound(arrTemp, 1)<\/code><\/p>\n<p>For j = LBound(arrTemp, 2) To UBound(arrTemp, 2)<\/p>\n<\/div>\n<p>\u4e8c\u6b21\u5143\u914d\u5217\u306e\u5024\u3092\u51fa\u529b\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>Debug.Print arrTemp(i, j)<\/code><\/div>\n<h2><span class=\"ez-toc-section\" id=\"VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A1%EF%BC%9AFor_Each%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\"><\/span>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2461\uff1aFor Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2461\uff1aFor Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"For_Each%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\"><\/span>For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<div class=\"info\"><code>For Each element In group<br \/>\n[statements]\n[Exit For]\n[statements]\nNext [element]<\/code><\/div>\n<p>For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306e\u6307\u5b9a\u9805\u76ee\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<table width=\"100%\">\n<tbody>\n<tr>\n<th>\u30d1\u30fc\u30c4<\/th>\n<th>\u8aac\u660e<\/th>\n<\/tr>\n<tr>\n<td>element<\/td>\n<td>\u5fc5\u9808\u3002 \u30b3\u30ec\u30af\u30b7\u30e7\u30f3\u307e\u305f\u306f\u914d\u5217\u306e\u8981\u7d20\u3092\u53cd\u5fa9\u51e6\u7406\u3059\u308b\u305f\u3081\u306b\u4f7f\u7528\u3055\u308c\u308b\u5909\u6570\u3067\u3059\u3002 \u30b3\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u5834\u5408\u3001\u8981\u7d20\u306b\u306fVariant\u5909\u6570\u3001\u6c4e\u7528\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u5909\u6570\u3001\u307e\u305f\u306f\u7279\u5b9a\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u5909\u6570\u306e\u307f\u3092\u6307\u5b9a\u3067\u304d\u307e\u3059\u3002 \u914d\u5217\u306e\u5834\u5408\u306f\u3001element\u306b\u4f7f\u7528\u3067\u304d\u308b\u306e\u306fVariant\u5909\u6570\u3060\u3051\u3067\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>group<\/td>\n<td>\u5fc5\u9808\u3002 \u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30b3\u30ec\u30af\u30b7\u30e7\u30f3\u307e\u305f\u306f\u914d\u5217\u306e\u540d\u524d\u3067\u3059 (\u30e6\u30fc\u30b6\u30fc\u5b9a\u7fa9\u578b\u306e\u914d\u5217\u3092\u9664\u304d\u307e\u3059)\u3002<\/td>\n<\/tr>\n<tr>\n<td>statements<\/td>\n<td>\u7701\u7565\u53ef\u80fd\u3002group\u306e\u5404\u30a2\u30a4\u30c6\u30e0\u306b\u5bfe\u3057\u3066\u5b9f\u884c\u3055\u308c\u308b 1 \u3064\u4ee5\u4e0a\u306e\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>Exit For<\/td>\n<td>For \u30eb\u30fc\u30d7\u3092\u629c\u3051\u307e\u3059\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u53c2\u8003\uff1ahttps:\/\/learn.microsoft.com\/ja-jp\/office\/vba\/language\/reference\/user-interface-help\/for-eachnext-statement<\/p>\n<p><!--\u5439\u304d\u51fa\u3057\u306f\u3058\u307e\u308a--><\/p>\n<div class=\"balloon5\">\n<div class=\"faceicon\">\n<img loading=\"lazy\" decoding=\"async\" src=\"\/wp-content\/uploads\/2020\/11\/taka_kao.gif\" alt=\"\u30bf\u30ab\u30d2\u30ed\" width=\"110\" height=\"110\" \/>\n<div class=\"faceiconfont\">\u30bf\u30ab\u30d2\u30ed<\/div>\n<\/div>\n<div class=\"chatting\">\n<div class=\"says\">For Each\u2026Next\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u4f7f\u3044\u65b9\u306e\u8a73\u7d30\u3092\u77e5\u308a\u305f\u3044\u65b9\u306f\u3053\u3061\u3089\u3092\u3054\u53c2\u7167\u304f\u3060\u3055\u3044\u3002<br \/>\n<a href=\"https:\/\/extan.jp\/?p=9612\">\u3010Excel VBA\u3011For Each Next\u6587\u306e\u4f7f\u3044\u65b9\uff01\u914d\u5217\u64cd\u4f5c\u3084\u629c\u3051\u308b\u65b9\u6cd5\u3082\uff01<\/a><\/div>\n<\/div>\n<\/div>\n<p><!--\u5439\u304d\u51fa\u3057\u7d42\u308f\u308a--><\/p>\n<h3><span class=\"ez-toc-section\" id=\"For_Each%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A1a\"><\/span>For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2461a<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-3\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2461a()\n    Dim intLastRowNum As Integer\n    Dim rngTemp As Range\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        For Each rngTemp In .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))\n            Debug.Print rngTemp.Cells(1, 1).Value\n        Next\n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-3\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code> 1<br \/>\nA<br \/>\n100<br \/>\n2<br \/>\nB<br \/>\n110<br \/>\n3<br \/>\nC<br \/>\n120<br \/>\n4<br \/>\nD<br \/>\n130<br \/>\n5<br \/>\nE<br \/>\n140<br \/>\n6<br \/>\nF<br \/>\n150<br \/>\n7<br \/>\nG<br \/>\n160<br \/>\n<\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-3\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u30bb\u30eb\u7bc4\u56f2\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002\u540c\u6642\u306b\u5909\u6570rngTemp\u3078\u30bb\u30eb\u7bc4\u56f2\u306e\u4e00\u90e8\u3092\u4ee3\u5165\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>For Each rngTemp In .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))<\/code><\/div>\n<p>rngTemp\u306e\u5de6\u4e0a\u30bb\u30eb\uff081,1\uff09\u306e\u5024\u3092\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code> Debug.Print rngTemp.Cells(1, 1).Value<\/code><\/div>\n<p><!--\u5439\u304d\u51fa\u3057\u306f\u3058\u307e\u308a--><\/p>\n<div class=\"balloon5\">\n<div class=\"faceicon\">\n<img loading=\"lazy\" decoding=\"async\" src=\"\/wp-content\/uploads\/2020\/11\/taka_kao.gif\" alt=\"\u30bf\u30ab\u30d2\u30ed\" width=\"110\" height=\"110\" \/>\n<div class=\"faceiconfont\">\u30bf\u30ab\u30d2\u30ed<\/div>\n<\/div>\n<div class=\"chatting\">\n<div class=\"says\">Variant\u578b\u3068\u3057\u3066\u6a5f\u80fd\u3057\u3066\u3044\u308b\u306e\u3067\u30bb\u30eb\u7bc4\u56f2\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u4ee5\u5916\u306b\u914d\u5217\u3084String\u578b\u306e\u5909\u6570\u3068\u3057\u3066\u3082\u6271\u3048\u307e\u3059\u3002\u3064\u307e\u308a\u300crngTemp(0)\u300d\u3084\u300crngTemp\u300d\u306e\u6307\u5b9a\u3067\u3082\u5024\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/div>\n<\/div>\n<\/div>\n<p><!--\u5439\u304d\u51fa\u3057\u7d42\u308f\u308a--><\/p>\n<h3><span class=\"ez-toc-section\" id=\"For_Each%E2%80%A6Next_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A1b\"><\/span>For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2461b<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-4\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>For Each&#8230;Next \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2461b()\n    Dim intLastRowNum As Integer\n    Dim arrTemps As Variant\n    Dim arrTemp As Variant\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        &#039;\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002\n        arrTemps = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))\n        \n        For Each arrTemp In arrTemps\n            Debug.Print arrTemp\n        Next\n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-4\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code> 1<br \/>\n2<br \/>\n3<br \/>\n4<br \/>\n5<br \/>\n6<br \/>\n7<br \/>\nA<br \/>\nB<br \/>\nC<br \/>\nD<br \/>\nE<br \/>\nF<br \/>\nG<br \/>\n100<br \/>\n110<br \/>\n120<br \/>\n130<br \/>\n140<br \/>\n150<br \/>\n160 <\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-4\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))<\/code><\/div>\n<p>For Each\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u914d\u5217\u30921\u4ef6\u3065\u3064\u53d6\u308a\u51fa\u3057\u914d\u5217\u4ef6\u6570\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>For Each arrTemp In arrTemps<\/code><\/div>\n<p>\u5909\u6570\u306e\u5024\u3092\u51fa\u529b\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>Debug.Print arrTemp<\/code><\/div>\n<h2><span class=\"ez-toc-section\" id=\"VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A2%EF%BC%9AWhile%E2%80%A6Wend_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\"><\/span>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2462\uff1aWhile&#8230;Wend \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2462\uff1aWhile&#8230;Wend \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"While%E2%80%A6Wend%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\"><\/span>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<div class=\"info\"><code>While condition<br \/>\n[statements]\nWend<\/code><\/div>\n<p>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306e\u6307\u5b9a\u9805\u76ee\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<table width=\"100%\">\n<tbody>\n<tr>\n<th>\u30d1\u30fc\u30c4<\/th>\n<th>\u8aac\u660e<\/th>\n<\/tr>\n<tr>\n<td>condition<\/td>\n<td>\u5fc5\u9808\u3002True\u307e\u305f\u306fFalse\u306b\u8a55\u4fa1\u3055\u308c\u308b\u6570\u5024\u5f0f\u307e\u305f\u306f\u6587\u5b57\u5217\u5f0f\u3067\u3059\u3002condition\u304cNull\u306e\u5834\u5408\u306f\u3001condition\u304cFalse\u3068\u3057\u3066\u51e6\u7406\u3055\u308c\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>statements<\/td>\n<td>\u7701\u7565\u53ef\u80fd\u3002 \u6761\u4ef6\u304cTrue\u306e\u9593\u306b\u5b9f\u884c\u3055\u308c\u308b 1 \u3064\u4ee5\u4e0a\u306e\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u3059\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u53c2\u8003\uff1ahttps:\/\/learn.microsoft.com\/ja-jp\/office\/vba\/language\/reference\/user-interface-help\/whilewend-statement<\/p>\n<h3><span class=\"ez-toc-section\" id=\"While%E2%80%A6Wend%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A2a\"><\/span>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2462a<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-5\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2462a()\n    Dim intLastRowNum As Integer\n    Dim i As Integer\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        i = 2\n        \n        While i &lt;= intLastRowNum\n            Debug.Print .Cells(i, 1).Value &amp; &quot;|&quot; &amp; .Cells(i, 2).Value &amp; &quot;|&quot; &amp; .Cells(i, 3).Value\n            i = i + 1\n        Wend\n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-5\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code>1|A|100<br \/>\n2|B|110<br \/>\n3|C|120<br \/>\n4|D|130<br \/>\n5|E|140<br \/>\n6|F|150<br \/>\n7|G|160<\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-5\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>\u958b\u59cb\u3059\u308b\u884c\u6570\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>i = 2<\/code><\/div>\n<p>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u6700\u7d42\u884c\u6570\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002\u6761\u4ef6\u9054\u6210\u306e\u305f\u3081\u306e\u52d5\u7684\u8981\u7d20\u3082\u5fc5\u8981\u3068\u306a\u308b\u305f\u3081\u5909\u6570i\u3092\u30a4\u30f3\u30af\u30ea\u30e1\u30f3\u30c8\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>While i &lt;= intLastRowNum<br \/>\ni = i + 1<\/code><\/div>\n<p>Cells\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306eValue\u30d7\u30ed\u30d1\u30c6\u30a3\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u3001 &#8220;|&#8221;\u533a\u5207\u308a\u3067\u6587\u5b57\u7d50\u5408\u3092\u3057\u3066\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code> Debug.Print .Cells(i, 1).Value &amp; &quot;|&quot; &amp; .Cells(i, 2).Value &amp; &quot;|&quot; &amp; .Cells(i, 3).Value<\/code><\/div>\n<h3><span class=\"ez-toc-section\" id=\"While%E2%80%A6Wend%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A2b\"><\/span>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2462b<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-6\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2462b()\n    Dim intLastRowNum As Integer\n    Dim arrTemp As Variant\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        &#039;\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002\n        arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))\n        \n        i = LBound(arrTemp, 1)\n        \n        While i &lt;= UBound(arrTemp, 1)\n            Debug.Print arrTemp(i, 1) &amp; &quot;|&quot; &amp; arrTemp(i, 2) &amp; &quot;|&quot; &amp; arrTemp(i, 3)\n            i = i + 1\n        Wend\n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-6\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code>1|A|100<br \/>\n2|B|110<br \/>\n3|C|120<br \/>\n4|D|130<br \/>\n5|E|140<br \/>\n6|F|150<br \/>\n7|G|160<\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-6\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))<\/code><\/div>\n<p>\u914d\u5217\u306e\u6700\u5c0f\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u3092\u53d6\u5f97\u3057\u3001\u5909\u6570\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>i = LBound(arrTemp, 1)<\/code><\/div>\n<p>While&#8230;Wend\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u6700\u7d42\u884c\u6570\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002\u6761\u4ef6\u9054\u6210\u306e\u305f\u3081\u306e\u52d5\u7684\u8981\u7d20\u3082\u5fc5\u8981\u3068\u306a\u308b\u305f\u3081\u5909\u6570i\u3092\u30a4\u30f3\u30af\u30ea\u30e1\u30f3\u30c8\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>While i &lt;= intLastRowNum<br \/>\ni = i + 1<\/code><\/div>\n<p>\u914d\u5217\u306e\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u3054\u3068\u306e\u5024\u3092\u53d6\u5f97\u3057\u3001 &#8220;|&#8221;\u533a\u5207\u308a\u3067\u6587\u5b57\u7d50\u5408\u3092\u3057\u3066\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code> Debug.Print arrTemp(i, 1) &amp; &quot;|&quot; &amp; arrTemp(i, 2) &amp; &quot;|&quot; &amp; arrTemp(i, 3)<\/code><\/div>\n<h2><span class=\"ez-toc-section\" id=\"VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A3%EF%BC%9ADo_While%E2%80%A6Loop_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\"><\/span>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2463\uff1aDo While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2463\uff1aDo While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Do_While%E2%80%A6Loop_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\"><\/span>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<div class=\"info\"><code>Do while condition<br \/>\n[statements]\nLoop<\/code><\/div>\n<p>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306e\u6307\u5b9a\u9805\u76ee\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<table width=\"100%\">\n<tbody>\n<tr>\n<th>\u30d1\u30fc\u30c4<\/th>\n<th>\u8aac\u660e<\/th>\n<\/tr>\n<tr>\n<td>condition<\/td>\n<td>\u7701\u7565\u53ef\u80fd\u3002True\u307e\u305f\u306fFalse\u306b\u8a55\u4fa1\u3055\u308c\u308b\u6570\u5f0f\u307e\u305f\u306f\u6587\u5b57\u5217\u5f0f\u3067\u3059\u3002condition\u304cNull\u306e\u5834\u5408\u3001condition\u306fFalse\u3068\u3057\u3066\u6271\u308f\u308c\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>statements<\/td>\n<td>condition\u304cTrue\u306e\u9593\u307e\u305f\u306f True \u306b\u306a\u308b\u307e\u3067\u7e70\u308a\u8fd4\u3057\u5b9f\u884c\u3059\u308b 1 \u3064\u4ee5\u4e0a\u306e\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u3059\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u53c2\u8003\uff1ahttps:\/\/learn.microsoft.com\/ja-jp\/office\/vba\/language\/reference\/user-interface-help\/doloop-statement<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Do_While%E2%80%A6Loop_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A3a\"><\/span>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2463a<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-7\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2463a()\n    Dim intLastRowNum As Integer\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        i = 2\n        \n        Do While i &lt;= intLastRowNum\n            Debug.Print .Cells(i, 1).Value &amp; &quot;|&quot; &amp; .Cells(i, 2).Value &amp; &quot;|&quot; &amp; .Cells(i, 3).Value\n            i = i + 1\n        Loop\n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-7\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code>1|A|100<br \/>\n2|B|110<br \/>\n3|C|120<br \/>\n4|D|130<br \/>\n5|E|140<br \/>\n6|F|150<br \/>\n7|G|160<\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-7\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>\u958b\u59cb\u3059\u308b\u884c\u6570\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>i = 2<\/code><\/div>\n<p>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u6700\u7d42\u884c\u6570\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002\u6761\u4ef6\u9054\u6210\u306e\u305f\u3081\u306e\u52d5\u7684\u8981\u7d20\u3082\u5fc5\u8981\u3068\u306a\u308b\u305f\u3081\u5909\u6570i\u3092\u30a4\u30f3\u30af\u30ea\u30e1\u30f3\u30c8\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>Do While i &lt;= intLastRowNum<br \/>\ni = i + 1<\/code><\/div>\n<p>Cells\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306eValue\u30d7\u30ed\u30d1\u30c6\u30a3\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u3001 &#8220;|&#8221;\u533a\u5207\u308a\u3067\u6587\u5b57\u7d50\u5408\u3092\u3057\u3066\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code> Debug.Print .Cells(i, 1).Value &amp; &quot;|&quot; &amp; .Cells(i, 2).Value &amp; &quot;|&quot; &amp; .Cells(i, 3).Value<\/code><\/div>\n<h3><span class=\"ez-toc-section\" id=\"Do_While%E2%80%A6Loop_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A3b\"><\/span>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2463b<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-8\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2463b()\n    Dim intLastRowNum As Integer\n    Dim arrTemp As Variant\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        &#039;\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002\n        arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))\n        \n        i = LBound(arrTemp, 1)\n        \n        Do While i &lt;= intLastRowNum\n            Debug.Print arrTemp(i, 1) &amp; &quot;|&quot; &amp; arrTemp(i, 2) &amp; &quot;|&quot; &amp; arrTemp(i, 3)\n            i = i + 1\n        Loop\n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-8\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code>1|A|100<br \/>\n2|B|110<br \/>\n3|C|120<br \/>\n4|D|130<br \/>\n5|E|140<br \/>\n6|F|150<br \/>\n7|G|160<\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-8\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))<\/code><\/div>\n<p>\u914d\u5217\u306e\u6700\u5c0f\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u3092\u53d6\u5f97\u3057\u3001\u5909\u6570\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>i = LBound(arrTemp, 1)<\/code><\/div>\n<p>Do While&#8230;Loop \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u6700\u7d42\u884c\u6570\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002\u6761\u4ef6\u9054\u6210\u306e\u305f\u3081\u306e\u52d5\u7684\u8981\u7d20\u3082\u5fc5\u8981\u3068\u306a\u308b\u305f\u3081\u5909\u6570i\u3092\u30a4\u30f3\u30af\u30ea\u30e1\u30f3\u30c8\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>Do While i &lt;= intLastRowNum<br \/>\ni = i + 1<\/code><\/div>\n<p>\u914d\u5217\u306e\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u3054\u3068\u306e\u5024\u3092\u53d6\u5f97\u3057\u3001 &#8220;|&#8221;\u533a\u5207\u308a\u3067\u6587\u5b57\u7d50\u5408\u3092\u3057\u3066\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code> Debug.Print arrTemp(i, 1) &amp; &quot;|&quot; &amp; arrTemp(i, 2) &amp; &quot;|&quot; &amp; arrTemp(i, 3)<\/code><\/div>\n<h2><span class=\"ez-toc-section\" id=\"VBA%E3%81%A7%E3%83%AB%E3%83%BC%E3%83%97%E3%81%A7%E3%82%BB%E3%83%AB%E3%81%AE%E5%80%A4%E3%82%92%E5%8F%96%E5%BE%97%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95%E2%91%A4%EF%BC%9ADo%E2%80%A6Loop_While_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%92%E4%BD%BF%E7%94%A8%E3%81%99%E3%82%8B\"><\/span>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2464\uff1aDo&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u2464\uff1aDo&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3092\u4f7f\u7528\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Do%E2%80%A6Loop_While_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%81%AE%E6%A7%8B%E6%96%87\"><\/span>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<div class=\"info\"><code>Do<br \/>\n[statements]\nLoop while condition<\/code><\/div>\n<p>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u306e\u69cb\u6587\u306e\u6307\u5b9a\u9805\u76ee\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<table width=\"100%\">\n<tbody>\n<tr>\n<th>\u30d1\u30fc\u30c4<\/th>\n<th>\u8aac\u660e<\/th>\n<\/tr>\n<tr>\n<td>condition<\/td>\n<td>\u7701\u7565\u53ef\u80fd\u3002True\u307e\u305f\u306fFalse\u306b\u8a55\u4fa1\u3055\u308c\u308b\u6570\u5f0f\u307e\u305f\u306f\u6587\u5b57\u5217\u5f0f\u3067\u3059\u3002condition\u304cNull\u306e\u5834\u5408\u3001condition\u306fFalse\u3068\u3057\u3066\u6271\u308f\u308c\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>statements<\/td>\n<td>condition\u304cTrue\u306e\u9593\u307e\u305f\u306f True \u306b\u306a\u308b\u307e\u3067\u7e70\u308a\u8fd4\u3057\u5b9f\u884c\u3059\u308b 1 \u3064\u4ee5\u4e0a\u306e\u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u3059\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u53c2\u8003\uff1ahttps:\/\/learn.microsoft.com\/ja-jp\/office\/vba\/language\/reference\/user-interface-help\/doloop-statement<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Do%E2%80%A6Loop_While_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E3%82%BB%E3%83%AB%E3%82%92%E7%9B%B4%E6%8E%A5%E5%8F%82%E7%85%A7%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A4a\"><\/span>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2464a<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-9\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u30bb\u30eb\u3092\u76f4\u63a5\u53c2\u7167\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2464a()\n    Dim intLastRowNum As Integer\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        i = 2\n        \n        Do\n            Debug.Print .Cells(i, 1).Value &amp; &quot;|&quot; &amp; .Cells(i, 2).Value &amp; &quot;|&quot; &amp; .Cells(i, 3).Value\n            i = i + 1\n        Loop While i &lt;= intLastRowNum\n        \n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-9\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code>1|A|100<br \/>\n2|B|110<br \/>\n3|C|120<br \/>\n4|D|130<br \/>\n5|E|140<br \/>\n6|F|150<br \/>\n7|G|160<\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-9\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>\u958b\u59cb\u3059\u308b\u884c\u6570\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>i = 2<\/code><\/div>\n<p>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u6700\u7d42\u884c\u6570\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002\u6761\u4ef6\u9054\u6210\u306e\u305f\u3081\u306e\u52d5\u7684\u8981\u7d20\u3082\u5fc5\u8981\u3068\u306a\u308b\u305f\u3081\u5909\u6570i\u3092\u30a4\u30f3\u30af\u30ea\u30e1\u30f3\u30c8\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>Do<br \/>\ni = i + 1<br \/>\nLoop While i &lt;= intLastRowNum<\/code><\/div>\n<p>Cells\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306eValue\u30d7\u30ed\u30d1\u30c6\u30a3\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u3001 &#8220;|&#8221;\u533a\u5207\u308a\u3067\u6587\u5b57\u7d50\u5408\u3092\u3057\u3066\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code> Debug.Print .Cells(i, 1).Value &amp; &quot;|&quot; &amp; .Cells(i, 2).Value &amp; &quot;|&quot; &amp; .Cells(i, 3).Value<\/code><\/div>\n<h3><span class=\"ez-toc-section\" id=\"Do%E2%80%A6Loop_While_%E3%82%B9%E3%83%86%E3%83%BC%E3%83%88%E3%83%A1%E3%83%B3%E3%83%88%E5%80%A4%E3%82%92%E4%BB%A3%E5%85%A5%E3%81%97%E3%81%9F%E9%85%8D%E5%88%97%E3%81%A7%E5%87%A6%E7%90%86%E3%81%99%E3%82%8B%E3%83%91%E3%82%BF%E3%83%BC%E3%83%B3%E2%91%A4b\"><\/span>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u2464b<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%B3%E3%83%BC%E3%83%89-10\"><\/span>VBA\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8+\u5024\u3092\u4ee3\u5165\u3057\u305f\u914d\u5217\u3067\u51e6\u7406\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u30b5\u30f3\u30d7\u30eb\u306eVBA\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre style=\"padding: 0;\"><code class=\"language-visual-basic line-numbers\">Sub \u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u2464b()\n    Dim intLastRowNum As Integer\n    Dim arrTemp As Variant\n    \n    &#039;&quot;Sheet1&quot;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002\n    With Sheets(&quot;Sheet1&quot;)\n        &#039;\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\n        intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row\n        \n        &#039;\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002\n        arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))\n        \n        i = LBound(arrTemp, 1)\n        \n        Do\n            Debug.Print arrTemp(i, 1) &amp; &quot;|&quot; &amp; arrTemp(i, 2) &amp; &quot;|&quot; &amp; arrTemp(i, 3)\n            i = i + 1\n        Loop While i &lt; intLastRowNum\n    End With\n\nEnd Sub<\/code><\/pre>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-10\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u3092\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u30a4\u30df\u30c7\u30a3\u30a8\u30a4\u30c8\u30a6\u30a3\u30f3\u30c9\u30a6\u306b\u30bb\u30eb\u306e\u5024\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u306d\uff01<\/p>\n<div class=\"info\"><code>1|A|100<br \/>\n2|B|110<br \/>\n3|C|120<br \/>\n4|D|130<br \/>\n5|E|140<br \/>\n6|F|150<br \/>\n7|G|160<\/code><\/div>\n<h4><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E8%AA%AC%E6%98%8E-10\"><\/span>VBA\u306e\u8aac\u660e<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>VBA\u306b\u3064\u3044\u3066\u8aac\u660e\u3092\u3057\u307e\u3059\u3002<\/p>\n<p>&#8220;Sheet1&#8243;\u30b7\u30fc\u30c8\u3092\u5bfe\u8c61\u306b\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>With Sheets(&quot;Sheet1&quot;)<\/code><\/div>\n<p>\u5bfe\u8c61\u306e\u8868\u306eA\u5217\u6700\u7d42\u884c\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>intLastRowNum = .Cells(Rows.Count, 1).End(xlUp).Row<\/code><\/div>\n<p>\u30bb\u30eb\u7bc4\u56f2\u3092\u4e8c\u6b21\u5143\u914d\u5217\u3068\u3057\u3066\u914d\u5217\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>arrTemp = .Range(.Cells(2, 1), .Cells(intLastRowNum, 3))<\/code><\/div>\n<p>\u914d\u5217\u306e\u6700\u5c0f\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u3092\u53d6\u5f97\u3057\u3001\u5909\u6570\u306b\u4ee3\u5165\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>i = LBound(arrTemp, 1)<\/code><\/div>\n<p>Do&#8230;Loop While \u30b9\u30c6\u30fc\u30c8\u30e1\u30f3\u30c8\u3067\u6700\u7d42\u884c\u6570\u5206\u51e6\u7406\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002\u6761\u4ef6\u9054\u6210\u306e\u305f\u3081\u306e\u52d5\u7684\u8981\u7d20\u3082\u5fc5\u8981\u3068\u306a\u308b\u305f\u3081\u5909\u6570i\u3092\u30a4\u30f3\u30af\u30ea\u30e1\u30f3\u30c8\u3057\u307e\u3059\u3002<\/p>\n<div class=\"info\"><code>Do<br \/>\ni = i + 1<br \/>\nLoop While i &lt; intLastRowNum<\/code><\/div>\n<p>\u914d\u5217\u306e\u30a4\u30f3\u30c7\u30c3\u30af\u30b9\u3054\u3068\u306e\u5024\u3092\u53d6\u5f97\u3057\u3001 &#8220;|&#8221;\u533a\u5207\u308a\u3067\u6587\u5b57\u7d50\u5408\u3092\u3057\u3066\u51fa\u529b\u3057\u307e\u3059\u3002<\/p>\n<h2><span class=\"ez-toc-section\" id=\"VBA%E3%81%AE%E5%AE%9F%E8%A3%85%E6%89%8B%E9%A0%86\"><\/span>VBA\u306e\u5b9f\u88c5\u624b\u9806<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>\u5b9f\u88c5\u624b\u9806\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<p>Excel\u5074\u306bVBA\u3092\u5b9f\u88c5\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u2460Excel\u3092\u65b0\u898f\u306b\u958b\u304d\u3001\u300c\u958b\u767a\u300d\u30bf\u30d6\u3092\u30af\u30ea\u30c3\u30af\u3057\u3001\u300cVisualBasic\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002<br \/>\n\u3082\u3057\u304f\u306f\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u30ad\u30fc\u300cAlt\u300d\uff0b\u300cF11\u300d\u3067\u3082OK\u3067\u3059\u3002<\/p>\n<p>\u2461\u6a19\u6e96\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002<br \/>\n\u5de6\u30da\u30a4\u30f3\u306eVBAProject\u3092\u53f3\u30af\u30ea\u30c3\u30af\u3057\u3001\u300c\u633f\u5165\u300d\u3001\u300c\u6a19\u6e96\u30e2\u30b8\u30e5\u30fc\u30eb\u300d\u3092\u9078\u629e\u3057\u307e\u3059\u3002<\/p>\n<img decoding=\"async\" src=\"https:\/\/extan.jp\/wp-content\/uploads\/2019\/05\/050919_1542_VBAFunctio2.png\" alt=\"\" \/>\n<p>\u2462\u53f3\u30da\u30a4\u30f3\u306e\u30a6\u30a4\u30f3\u30c9\u30a6\u306b\u4e0a\u8a18\u306eVBA\u3092\u5165\u529b\u3057\u307e\u3059\u3002<br \/>\n<img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1680\" src=\"https:\/\/extan.jp\/wp-content\/uploads\/2019\/09\/092219_1211_temp22.png\" alt=\"\" width=\"1395\" height=\"879\" \/><\/p>\n<p>\u3053\u3061\u3089\u3067\u5b8c\u4e86\u3067\u3059\u3002<\/p>\n<h2><span class=\"ez-toc-section\" id=\"VBA%E3%82%92%E5%AE%9F%E8%A1%8C%E3%81%99%E3%82%8B-11\"><\/span>VBA\u3092\u5b9f\u884c\u3059\u308b<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>\u3067\u306f\u65e9\u901fVBA\u306e\u5b9f\u884c\u3092\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u2460\u300c\u958b\u767a\u300d\u30bf\u30d6\u306e\u300cVBA\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u5b9f\u884c\u3057\u305f\u3044\u30de\u30af\u30ed\u3092\u9078\u629e\u3057\u3001\u300c<strong>\u5b9f\u884c<\/strong>\u300d\u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059\u3002<\/p>\n<p>\u2461\u51e6\u7406\u304c\u3055\u308c\u305f\u3053\u3068\u304c\u78ba\u8a8d\u3067\u304d\u308c\u3070\u5b8c\u4e86\u3067\u3059\u3002<\/p>\n<h2><span class=\"ez-toc-section\" id=\"%E3%81%95%E3%81%84%E3%81%94%E3%81%AB\"><\/span>\u3055\u3044\u3054\u306b<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>\u3044\u304b\u304c\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n<p>\u4eca\u56de\u306f\u3001<\/p>\n<div class=\"endinfo\">\u30fbVBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\u3068\u30b5\u30f3\u30d7\u30eb\u8868\u3092\u4f7f\u3063\u305f\u9069\u7528\u4f8b<\/div>\n<p>\u306b\u3064\u3044\u3066\u307e\u3068\u3081\u307e\u3057\u305f\u3002<\/p>\n<p>\u307e\u305f\u3001\u4ed6\u306b\u3082\u4fbf\u5229\u306a\u65b9\u6cd5\u304c\u3042\u308a\u307e\u3059\u306e\u3067\u3001\u3088\u308d\u3057\u3051\u308c\u3070\u3054\u53c2\u7167\u9802\u3051\u308c\u3070\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u305f\u3044\u3068\u304d\u306f\u306a\u3044\u3067\u3057\u3087\u3046\u304b\u3002 \u3051\u3069\u3001\u305d\u3093\u306a\u4e2d\u3067\u60a9\u3080\u3053\u3068\u306f\u3001 \u30fbVBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u305f\u3044\u304c\u65b9\u6cd5\u304c\u3088\u304f\u308f\u304b\u3089\u306a\u3044 \u30fbVBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3057\u305f\u304c\u601d\u3046\u3088\u3046\u306b\u53d6\u5f97\u3067\u304d\u305a\u56f0\u3063\u3066\u3044\u308b&#8230;<\/p>\n","protected":false},"author":1,"featured_media":9617,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[191],"class_list":{"0":"post-9564","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-excelvba","8":"tag-191","9":"article cf"},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v18.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<meta name=\"description\" content=\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\u3068\u30b5\u30f3\u30d7\u30eb\u8868\u3092\u4f7f\u3063\u305f\u9069\u7528\u4f8b\u306b\u3064\u3044\u3066\u307e\u3068\u3081\u307e\u3059\u3002\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/extan.jp\/?p=9564\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01 - \u30a8\u30af\u77ed\uff5cExtan.jp\" \/>\n<meta property=\"og:description\" content=\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\u3068\u30b5\u30f3\u30d7\u30eb\u8868\u3092\u4f7f\u3063\u305f\u9069\u7528\u4f8b\u306b\u3064\u3044\u3066\u307e\u3068\u3081\u307e\u3059\u3002\" \/>\n<meta property=\"og:url\" content=\"https:\/\/extan.jp\/?p=9564\" \/>\n<meta property=\"og:site_name\" content=\"\u30a8\u30af\u77ed\uff5cExtan.jp\" \/>\n<meta property=\"article:published_time\" content=\"2022-09-20T08:26:15+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-09-25T15:28:47+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/str-131.png\" \/>\n\t<meta property=\"og:image:width\" content=\"857\" \/>\n\t<meta property=\"og:image:height\" content=\"607\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u57f7\u7b46\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u30bf\u30ab\u30d2\u30ed@extan\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593\" \/>\n\t<meta name=\"twitter:data2\" content=\"33\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/extan.jp\/#website\",\"url\":\"https:\/\/extan.jp\/\",\"name\":\"\u30a8\u30af\u77ed\uff5cExtan.jp\",\"description\":\"\u50cd\u304f\u4eba\u306e\u81ea\u7531\u6642\u9593\u3092\u3064\u304f\u308b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/extan.jp\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"ja\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/extan.jp\/?p=9564#primaryimage\",\"inLanguage\":\"ja\",\"url\":\"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/str-131.png\",\"contentUrl\":\"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/str-131.png\",\"width\":857,\"height\":607,\"caption\":\"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/extan.jp\/?p=9564#webpage\",\"url\":\"https:\/\/extan.jp\/?p=9564\",\"name\":\"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01 - \u30a8\u30af\u77ed\uff5cExtan.jp\",\"isPartOf\":{\"@id\":\"https:\/\/extan.jp\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/extan.jp\/?p=9564#primaryimage\"},\"datePublished\":\"2022-09-20T08:26:15+00:00\",\"dateModified\":\"2022-09-25T15:28:47+00:00\",\"author\":{\"@id\":\"https:\/\/extan.jp\/#\/schema\/person\/ccb8849fcf749d5f74439b1af7d4df1a\"},\"description\":\"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\u3068\u30b5\u30f3\u30d7\u30eb\u8868\u3092\u4f7f\u3063\u305f\u9069\u7528\u4f8b\u306b\u3064\u3044\u3066\u307e\u3068\u3081\u307e\u3059\u3002\",\"breadcrumb\":{\"@id\":\"https:\/\/extan.jp\/?p=9564#breadcrumb\"},\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/extan.jp\/?p=9564\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/extan.jp\/?p=9564#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u30db\u30fc\u30e0\",\"item\":\"https:\/\/extan.jp\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01\"}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/extan.jp\/#\/schema\/person\/ccb8849fcf749d5f74439b1af7d4df1a\",\"name\":\"\u30bf\u30ab\u30d2\u30ed@extan\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/extan.jp\/#personlogo\",\"inLanguage\":\"ja\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/24a74fef504a714c468411d23f2d1fd451892ffebbba0d84f70d4ce0d489aefb?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/24a74fef504a714c468411d23f2d1fd451892ffebbba0d84f70d4ce0d489aefb?s=96&d=mm&r=g\",\"caption\":\"\u30bf\u30ab\u30d2\u30ed@extan\"},\"url\":\"https:\/\/extan.jp\/?author=1\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"description":"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\u3068\u30b5\u30f3\u30d7\u30eb\u8868\u3092\u4f7f\u3063\u305f\u9069\u7528\u4f8b\u306b\u3064\u3044\u3066\u307e\u3068\u3081\u307e\u3059\u3002","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/extan.jp\/?p=9564","og_locale":"ja_JP","og_type":"article","og_title":"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01 - \u30a8\u30af\u77ed\uff5cExtan.jp","og_description":"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\u3068\u30b5\u30f3\u30d7\u30eb\u8868\u3092\u4f7f\u3063\u305f\u9069\u7528\u4f8b\u306b\u3064\u3044\u3066\u307e\u3068\u3081\u307e\u3059\u3002","og_url":"https:\/\/extan.jp\/?p=9564","og_site_name":"\u30a8\u30af\u77ed\uff5cExtan.jp","article_published_time":"2022-09-20T08:26:15+00:00","article_modified_time":"2022-09-25T15:28:47+00:00","og_image":[{"width":857,"height":607,"url":"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/str-131.png","type":"image\/png"}],"twitter_card":"summary_large_image","twitter_misc":{"\u57f7\u7b46\u8005":"\u30bf\u30ab\u30d2\u30ed@extan","\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593":"33\u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebSite","@id":"https:\/\/extan.jp\/#website","url":"https:\/\/extan.jp\/","name":"\u30a8\u30af\u77ed\uff5cExtan.jp","description":"\u50cd\u304f\u4eba\u306e\u81ea\u7531\u6642\u9593\u3092\u3064\u304f\u308b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/extan.jp\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"ja"},{"@type":"ImageObject","@id":"https:\/\/extan.jp\/?p=9564#primaryimage","inLanguage":"ja","url":"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/str-131.png","contentUrl":"https:\/\/extan.jp\/wp-content\/uploads\/2022\/09\/str-131.png","width":857,"height":607,"caption":"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01"},{"@type":"WebPage","@id":"https:\/\/extan.jp\/?p=9564#webpage","url":"https:\/\/extan.jp\/?p=9564","name":"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01 - \u30a8\u30af\u77ed\uff5cExtan.jp","isPartOf":{"@id":"https:\/\/extan.jp\/#website"},"primaryImageOfPage":{"@id":"https:\/\/extan.jp\/?p=9564#primaryimage"},"datePublished":"2022-09-20T08:26:15+00:00","dateModified":"2022-09-25T15:28:47+00:00","author":{"@id":"https:\/\/extan.jp\/#\/schema\/person\/ccb8849fcf749d5f74439b1af7d4df1a"},"description":"VBA\u3067\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\u3068\u30b5\u30f3\u30d7\u30eb\u8868\u3092\u4f7f\u3063\u305f\u9069\u7528\u4f8b\u306b\u3064\u3044\u3066\u307e\u3068\u3081\u307e\u3059\u3002","breadcrumb":{"@id":"https:\/\/extan.jp\/?p=9564#breadcrumb"},"inLanguage":"ja","potentialAction":[{"@type":"ReadAction","target":["https:\/\/extan.jp\/?p=9564"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/extan.jp\/?p=9564#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u30db\u30fc\u30e0","item":"https:\/\/extan.jp\/"},{"@type":"ListItem","position":2,"name":"\u3010Excel VBA\u3011\u30eb\u30fc\u30d7\u3067\u30bb\u30eb\u306e\u5024\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd510\u9078\uff01"}]},{"@type":"Person","@id":"https:\/\/extan.jp\/#\/schema\/person\/ccb8849fcf749d5f74439b1af7d4df1a","name":"\u30bf\u30ab\u30d2\u30ed@extan","image":{"@type":"ImageObject","@id":"https:\/\/extan.jp\/#personlogo","inLanguage":"ja","url":"https:\/\/secure.gravatar.com\/avatar\/24a74fef504a714c468411d23f2d1fd451892ffebbba0d84f70d4ce0d489aefb?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/24a74fef504a714c468411d23f2d1fd451892ffebbba0d84f70d4ce0d489aefb?s=96&d=mm&r=g","caption":"\u30bf\u30ab\u30d2\u30ed@extan"},"url":"https:\/\/extan.jp\/?author=1"}]}},"_links":{"self":[{"href":"https:\/\/extan.jp\/index.php?rest_route=\/wp\/v2\/posts\/9564","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/extan.jp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/extan.jp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/extan.jp\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/extan.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=9564"}],"version-history":[{"count":9,"href":"https:\/\/extan.jp\/index.php?rest_route=\/wp\/v2\/posts\/9564\/revisions"}],"predecessor-version":[{"id":9693,"href":"https:\/\/extan.jp\/index.php?rest_route=\/wp\/v2\/posts\/9564\/revisions\/9693"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/extan.jp\/index.php?rest_route=\/wp\/v2\/media\/9617"}],"wp:attachment":[{"href":"https:\/\/extan.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=9564"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/extan.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=9564"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/extan.jp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=9564"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}