﻿{"id":623,"date":"2012-07-03T16:05:24","date_gmt":"2012-07-03T07:05:24","guid":{"rendered":"http:\/\/fujiitoshiki.com\/improvesociety\/?p=623"},"modified":"2014-11-07T16:50:59","modified_gmt":"2014-11-07T07:50:59","slug":"post-623","status":"publish","type":"post","link":"https:\/\/www.fujiitoshiki.com\/improvesociety\/?p=623","title":{"rendered":"\u6539\u8a02\u7248\u300e\u8eab\u4f53\u6d3b\u52d5\u306e\u30e1\u30c3\u30c4\u8868\u300f\u304b\u3089\u30c6\u30ad\u30b9\u30c8\u3092\u62bd\u51fa\u3059\u308b"},"content":{"rendered":"<div class=\"theContentWrap-ccc\"><p><a href=\"\/\/px.a8.net\/svt\/ejp?a8mat=2BTZJ1+CKHGJ6+2NQE+669JL\" target=\"_blank\"><br \/>\n<img loading=\"lazy\" decoding=\"async\" border=\"0\" width=\"300\" height=\"250\" alt=\"\" src=\"\/\/www21.a8.net\/svt\/bgt?aid=140807197760&#038;wid=001&#038;eno=01&#038;mid=s00000012407001037000&#038;mc=1\"><\/a><br \/>\n<img loading=\"lazy\" decoding=\"async\" border=\"0\" width=\"1\" height=\"1\" src=\"\/\/www10.a8.net\/0.gif?a8mat=2BTZJ1+CKHGJ6+2NQE+669JL\" alt=\"\"><\/p>\n<p>\u3000\u56fd\u7acb\u5065\u5eb7\u30fb\u6804\u990a\u7814\u7a76\u6240\u304c2011\u5e74\u7248\u300e\u8eab\u4f53\u6d3b\u52d5\u306e\u30e1\u30c3\u30c4\u8868\u300f\u3092\u6539\u8a02\u3057\u307e\u3057\u305f\uff0e\u4e0b\u8a18\u30ea\u30f3\u30af\u306fPDF\u30d5\u30a1\u30a4\u30eb\u3067\u3059\u304c\uff0c\u305d\u306e\u307e\u307e\u3067\u306f\u4f7f\u3044\u306b\u304f\u3044\u305f\u3081EXCEL\u3067\u30c6\u30ad\u30b9\u30c8\u60c5\u5831\u3092\u62bd\u51fa\u3057\u307e\u3057\u305f\uff0e2012\u5e747\u67083\u65e5\uff0c\u56fd\u7acb\u5065\u5eb7\u30fb\u6804\u990a\u7814\u7a76\u6240\u306b\u62bd\u51fa\u3057\u305f\u30c6\u30ad\u30b9\u30c8\u30d5\u30a1\u30a4\u30eb\u3092\u516c\u958b\u3057\u3066\u826f\u3044\u304b\u554f\u3044\u5408\u308f\u305b\u307e\u3057\u305f\uff0e<\/p>\n<p><a href=\"\/\/www0.nih.go.jp\/eiken\/programs\/2011mets.pdf\" title=\"\u8eab\u4f53\u6d3b\u52d5\u306e\u30e1\u30c3\u30c4\u8868\" target=\"_blank\">\u8eab\u4f53\u6d3b\u52d5\u306e\u30e1\u30c3\u30c4\u8868<\/a><\/p>\n<p><a href=\"\/\/px.a8.net\/svt\/ejp?a8mat=2BU0BK+F4RNAQ+3RK+3T3HGX\" target=\"_blank\"><br \/>\n<img loading=\"lazy\" decoding=\"async\" border=\"0\" width=\"468\" height=\"60\" alt=\"\" src=\"\/\/www29.a8.net\/svt\/bgt?aid=140808224915&#038;wid=001&#038;eno=01&#038;mid=s00000000488023027000&#038;mc=1\"><\/a><br \/>\n<img loading=\"lazy\" decoding=\"async\" border=\"0\" width=\"1\" height=\"1\" src=\"\/\/www18.a8.net\/0.gif?a8mat=2BU0BK+F4RNAQ+3RK+3T3HGX\" alt=\"\"><\/p>\n<p>1. PDF\u30d5\u30a1\u30a4\u30eb\u3092\u958b\u304d\uff0c\u5168\u3066\u3092\u9078\u629e\u3057\u3066\u30b3\u30d4\u30fc\u3057\u307e\u3059\uff0e<\/p>\n<p>2. EXCEL\u306e\u65b0\u898f\u30d6\u30c3\u30af\u3092\u4f5c\u6210\u3057\uff0c\u30c6\u30ad\u30b9\u30c8\u30d5\u30a1\u30a4\u30eb\u30a6\u30a3\u30b6\u30fc\u30c9\u3092\u4f7f\u7528\u3057\u3066\u8cbc\u308a\u4ed8\u3051\u307e\u3059\uff0e\u3053\u306e\u969b\uff0c\u30c6\u30ad\u30b9\u30c8\u30d5\u30a1\u30a4\u30eb\u30a6\u30a3\u30b6\u30fc\u30c9\u306e2\u756a\u76ee\u306e\u30bf\u30d6\u3067\u533a\u5207\u308a\u6587\u5b57\u306e\u5168\u3066\u306e\u30c1\u30a7\u30c3\u30af\u3092\u5916\u3057\u3066\u4e0b\u3055\u3044\uff0e3\u756a\u76ee\u306e\u30bf\u30d6\u3067\u306f\u5217\u306e\u30c7\u30fc\u30bf\u5f62\u5f0f\u3092\u300e\u6587\u5b57\u5217\u300f\u306b\u5909\u66f4\u3057\u3066\u4e0b\u3055\u3044\uff0e<\/p>\n<p>3. &#8216;Alt&#8217; \u30ad\u30fc\u3068 &#8216;F11&#8217; \u30ad\u30fc\u3092\u62bc\u4e0b\u3057\u3066 VBE \u3092\u8d77\u52d5\u3057\uff0c\u6a19\u6e96\u30e2\u30b8\u30e5\u30fc\u30eb\u3092\u633f\u5165\u3057\u3066\u4e0b\u8a18\u30b3\u30fc\u30c9\u3092\u5b9f\u884c\u3057\u3066\u4e0b\u3055\u3044\uff0e<\/p>\n<pre class=\"lang:vb decode:true \" >Option Explicit\r\nSub METS()\r\nDim mySht   As Worksheet\r\nDim myRng   As Range\r\nDim myAr    As Variant\r\nDim i       As Long\r\nDim j       As Long\r\nDim myReg   As Object\r\nDim myMatches   As Object\r\nDim myMatch     As Object\r\nConst strReg    As String = \"^[0-9]{5}$\"\r\nDim CODE()  As String\r\nDim METS()  As Single\r\nDim MajorHeading()  As String\r\nDim SpecificActivities()    As String\r\nDim myArray()   As Variant\r\nSet myReg = CreateObject(\"VBScript.RegExp\")\r\nWith myReg\r\n    .Pattern = strReg\r\n    .IgnoreCase = True\r\n    .Global = True\r\nEnd With\r\n\r\nSet mySht = ActiveSheet\r\nSet myRng = mySht.UsedRange\r\nmyAr = myRng\r\nj = 0\r\nFor i = LBound(myAr) To UBound(myAr)\r\n    If myReg.Test(myAr(i, 1)) Then\r\n        Set myMatches = myReg.Execute(myAr(i, 1))\r\n        ReDim Preserve CODE(j)\r\n        ReDim Preserve METS(j)\r\n        ReDim Preserve MajorHeading(j)\r\n        ReDim Preserve SpecificActivities(j)\r\n        CODE(j) = myAr(i, 1)\r\n        METS(j) = myAr(i + 1, 1)\r\n        MajorHeading(j) = myAr(i + 2, 1)\r\n        SpecificActivities(j) = myAr(i + 3, 1)\r\n        j = j + 1\r\n    End If\r\nNext i\r\nReDim myArray(j, 3)\r\nFor j = LBound(myArray) To UBound(myArray) - 1\r\n    myArray(j, 0) = CODE(j)\r\n    myArray(j, 1) = METS(j)\r\n    myArray(j, 2) = MajorHeading(j)\r\n    myArray(j, 3) = SpecificActivities(j)\r\nNext j\r\nSet mySht = Worksheets.Add\r\nmySht.Range(\"A1\").Value = \"CODE\"\r\nmySht.Range(\"B1\").Value = \"METS\"\r\nmySht.Range(\"C1\").Value = \"MajorHeading\"\r\nmySht.Range(\"D1\").Value = \"SpecificActivities\"\r\nmySht.Range(\"A2:D827\") = myArray\r\nEnd Sub\r\n<\/pre>\n<p><iframe src=\"\/\/rcm-fe.amazon-adsystem.com\/e\/cm?lt1=_blank&#038;bc1=000000&#038;IS2=1&#038;bg1=FFFFFF&#038;fc1=000000&#038;lc1=0000FF&#038;t=fujiitoshiki-22&#038;o=9&#038;p=8&#038;l=as4&#038;m=amazon&#038;f=ifr&#038;ref=ss_til&#038;asins=479736761X\" style=\"width:120px;height:240px;\" scrolling=\"no\" marginwidth=\"0\" marginheight=\"0\" frameborder=\"0\"><\/iframe><\/p>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>\u3000\u56fd\u7acb\u5065\u5eb7\u30fb\u6804\u990a\u7814\u7a76\u6240\u304c2011\u5e74\u7248\u300e\u8eab\u4f53\u6d3b\u52d5\u306e\u30e1\u30c3\u30c4\u8868\u300f\u3092\u6539\u8a02\u3057\u307e\u3057\u305f\uff0e\u4e0b\u8a18\u30ea\u30f3\u30af\u306fPDF\u30d5\u30a1\u30a4\u30eb\u3067\u3059\u304c\uff0c\u305d\u306e\u307e\u307e\u3067\u306f\u4f7f\u3044\u306b\u304f\u3044\u305f\u3081EXCEL\u3067\u30c6\u30ad\u30b9\u30c8\u60c5\u5831\u3092\u62bd\u51fa\u3057\u307e\u3057\u305f\uff0e2012\u5e747\u67083\u65e5\uff0c\u56fd\u7acb\u5065\u5eb7\u30fb\u6804\u990a\u7814\u7a76\u6240\u306b\u62bd\u51fa &hellip; <a href=\"https:\/\/www.fujiitoshiki.com\/improvesociety\/?p=623\" class=\"more-link\"><span class=\"screen-reader-text\">&#8220;\u6539\u8a02\u7248\u300e\u8eab\u4f53\u6d3b\u52d5\u306e\u30e1\u30c3\u30c4\u8868\u300f\u304b\u3089\u30c6\u30ad\u30b9\u30c8\u3092\u62bd\u51fa\u3059\u308b&#8221; \u306e<\/span>\u7d9a\u304d\u3092\u8aad\u3080<\/a><\/p>\n","protected":false},"author":1,"featured_media":6026,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_crdt_document":"","_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[6,4],"tags":[603,153,270,269],"class_list":["post-623","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-excel","category-nutrition","tag-excel","tag-vba","tag-270","tag-269"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=\/wp\/v2\/posts\/623","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=623"}],"version-history":[{"count":17,"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=\/wp\/v2\/posts\/623\/revisions"}],"predecessor-version":[{"id":642,"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=\/wp\/v2\/posts\/623\/revisions\/642"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=\/wp\/v2\/media\/6026"}],"wp:attachment":[{"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=623"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=623"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.fujiitoshiki.com\/improvesociety\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=623"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}