{"id":5664,"date":"2016-08-04T08:25:00","date_gmt":"2016-08-03T23:25:00","guid":{"rendered":"http:\/\/excelwork.info\/excel\/?p=5664"},"modified":"2016-08-04T08:30:37","modified_gmt":"2016-08-03T23:30:37","slug":"listobjectrange","status":"publish","type":"post","link":"https:\/\/excelwork.info\/excel\/listobjectrange\/","title":{"rendered":"ListObject \u306e\u30d7\u30ed\u30d1\u30c6\u30a3\uff08Range\u3001HeaderRowRange\u3001DataBodyRange\uff09"},"content":{"rendered":"<h2>ListObject \u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30d7\u30ed\u30d1\u30c6\u30a3\uff08Range \u30d7\u30ed\u30d1\u30c6\u30a3\u3001HeaderRowRange \u30d7\u30ed\u30d1\u30c6\u30a3\u3001DataBodyRange \u30d7\u30ed\u30d1\u30c6\u30a3\uff09<\/h2>\n<div class=\"m30-l\">\n<p>\u30c6\u30fc\u30d6\u30eb\uff08\u30ea\u30b9\u30c8\uff09\u6a5f\u80fd\u3092\u4f7f\u7528\u3059\u308b\u306b\u306f\u3001<a href=\"https:\/\/excelwork.info\/excel\/listobjects\/\">ListObjects \u30b3\u30ec\u30af\u30b7\u30e7\u30f3<\/a>\uff08\u30ef\u30fc\u30af\u30b7\u30fc\u30c8\u5185\u306e\u3059\u3079\u3066\u306e\u30c6\u30fc\u30d6\u30eb\uff09\u3001<a href=\"https:\/\/excelwork.info\/excel\/listobject\/\">ListObject \u30aa\u30d6\u30b8\u30a7\u30af\u30c8<\/a>\uff08\uff11\u3064\u306e\u30c6\u30fc\u30d6\u30eb\uff09\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<br \/>\n<h3 id=\"loRange\">Range \u30d7\u30ed\u30d1\u30c6\u30a3<\/h3>\n<p>\u30ef\u30fc\u30af\u30b7\u30fc\u30c8\u4e0a\u306e\u30c6\u30fc\u30d6\u30eb\uff08\u30ea\u30b9\u30c8\uff09\u306e\u30bb\u30eb\u7bc4\u56f2\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<br \/>\n<div class=\"kkbox\"><strong>\u3010\u66f8\u5f0f\u3011<\/strong><\/p>\n<p>    <span class=\"red\"><strong>\uff1c\u53d6\u5f97\uff1e<\/strong><\/span><br \/>\n    <em>object<\/em>.<strong>Range<\/strong><\/p><\/div>\n<br \/>\n<h4>\u5f15\u6570\u30fb\u623b\u308a\u5024<\/h4>\n<div class=\"m30-l\">\n<ul style=\"margin-top:0;margin-bottom:0;padding-top:0;padding-bottom:0;\">\n<li>object&nbsp;&nbsp;\u30fb\u30fb\u30fb&nbsp;&nbsp;\u5bfe\u8c61\u3068\u306a\u308b <span class=\"red\"><strong>ListObject \u30aa\u30d6\u30b8\u30a7\u30af\u30c8<\/strong><\/span>\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/li>\n<li>\u623b\u308a\u5024&nbsp;&nbsp;\u30fb\u30fb\u30fb&nbsp;&nbsp;\u30c6\u30fc\u30d6\u30eb\u306e\u30bb\u30eb\u7bc4\u56f2\uff08Range \u30aa\u30d6\u30b8\u30a7\u30af\u30c8\uff09<\/li>\n<\/ul>\n<br \/><\/div>\n<br \/><br \/>\n<h3 id=\"lohrowRange\">HeaderRowRange \u30d7\u30ed\u30d1\u30c6\u30a3<\/h3>\n<p>\u30ef\u30fc\u30af\u30b7\u30fc\u30c8\u4e0a\u306e\u30c6\u30fc\u30d6\u30eb\uff08\u30ea\u30b9\u30c8\uff09\u306e\u898b\u51fa\u3057\u90e8\u5206\u306e\u30bb\u30eb\u7bc4\u56f2\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<br \/>\n<div class=\"kkbox\"><strong>\u3010\u66f8\u5f0f\u3011<\/strong><\/p>\n<p>    <span class=\"red\"><strong>\uff1c\u53d6\u5f97\uff1e<\/strong><\/span><br \/>\n    <em>object<\/em>.<strong>HeaderRowRange<\/strong><\/p><\/div>\n<br \/>\n<h4>\u5f15\u6570\u30fb\u623b\u308a\u5024<\/h4>\n<div class=\"m30-l\">\n<ul style=\"margin-top:0;margin-bottom:0;padding-top:0;padding-bottom:0;\">\n<li>object&nbsp;&nbsp;\u30fb\u30fb\u30fb&nbsp;&nbsp;\u5bfe\u8c61\u3068\u306a\u308b <span class=\"red\"><strong>ListObject \u30aa\u30d6\u30b8\u30a7\u30af\u30c8<\/strong><\/span>\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/li>\n<li>\u623b\u308a\u5024&nbsp;&nbsp;\u30fb\u30fb\u30fb&nbsp;&nbsp;\u30c6\u30fc\u30d6\u30eb\u306e\u898b\u51fa\u3057\u90e8\u5206\u306e\u30bb\u30eb\u7bc4\u56f2\uff08Range \u30aa\u30d6\u30b8\u30a7\u30af\u30c8\uff09<\/li>\n<\/ul>\n<br \/><\/div>\n<br \/><br \/>\n<h3 id=\"lodbodyRange\">DataBodyRange \u30d7\u30ed\u30d1\u30c6\u30a3<\/h3>\n<p>\u30ef\u30fc\u30af\u30b7\u30fc\u30c8\u4e0a\u306e\u30c6\u30fc\u30d6\u30eb\uff08\u30ea\u30b9\u30c8\uff09\u306e\u898b\u51fa\u3057\u90e8\u5206\u3092\u9664\u3044\u305f\u30bb\u30eb\u7bc4\u56f2\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<br \/>\n<div class=\"kkbox\"><strong>\u3010\u66f8\u5f0f\u3011<\/strong><\/p>\n<p>    <span class=\"red\"><strong>\uff1c\u53d6\u5f97\uff1e<\/strong><\/span><br \/>\n    <em>object<\/em>.<strong>DataBodyRange<\/strong><\/p><\/div>\n<br \/>\n<h4>\u5f15\u6570\u30fb\u623b\u308a\u5024<\/h4>\n<div class=\"m30-l\">\n<ul style=\"margin-top:0;margin-bottom:0;padding-top:0;padding-bottom:0;\">\n<li>object&nbsp;&nbsp;\u30fb\u30fb\u30fb&nbsp;&nbsp;\u5bfe\u8c61\u3068\u306a\u308b <span class=\"red\"><strong>ListObject \u30aa\u30d6\u30b8\u30a7\u30af\u30c8<\/strong><\/span>\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002<\/li>\n<li>\u623b\u308a\u5024&nbsp;&nbsp;\u30fb\u30fb\u30fb&nbsp;&nbsp;\u30c6\u30fc\u30d6\u30eb\u306e\u898b\u51fa\u3057\u90e8\u5206\u3092\u9664\u3044\u305f\u30bb\u30eb\u7bc4\u56f2\uff08Range \u30aa\u30d6\u30b8\u30a7\u30af\u30c8\uff09<\/li>\n<\/ul>\n<br \/><\/div>\n<\/div>\n<br \/><br \/>\n<h2>ListObject \u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30d7\u30ed\u30d1\u30c6\u30a3\uff08Range\u3001HeaderRowRange\u3001DataBodyRange\uff09\u4f7f\u7528\u4f8b<\/h2>\n<div class=\"m30-l\">\n<h3 id=\"vba_sample\">\u30b5\u30f3\u30d7\u30ebVBA\u30bd\u30fc\u30b9<\/h3>\n<pre class=\"lang:vb mark:0 decode:true \" title=\"Range\u3001HeaderRowRange\u3001DataBodyRange \u4f7f\u7528\u4f8b\" data-url=\"http:\/\/example.co.jp\" >\r\n\u3000\r\nSub Sample_ListObject01()\r\n\r\n    Sheets(\"Sheet5\").Activate\r\n    \r\n    Dim mysheet As Worksheet\r\n    Dim mytbl As ListObject\r\n    Dim str As String\r\n    \r\n    Set mysheet = ActiveWorkbook.ActiveSheet\r\n    \r\n    On Error GoTo ErrH\r\n    \r\n    Set mytbl = mysheet.ListObjects.Item(\"\u6210\u7e3e\u886802\")\r\n    \r\n    str = \"\u30c6\u30fc\u30d6\u30eb\u7bc4\u56f2\uff1a\" & mytbl.Range.Address(rowabsolute:=False, columnabsolute:=False) & vbCrLf\r\n    str = str & \"\u898b\u51fa\u3057\u7bc4\u56f2\uff1a\" & mytbl.HeaderRowRange.Address(rowabsolute:=False, columnabsolute:=False) & vbCrLf\r\n    str = str & \"\u30c7\u30fc\u30bf\u7bc4\u56f2\uff1a\" & mytbl.DataBodyRange.Address(rowabsolute:=False, columnabsolute:=False)\r\n    \r\n    MsgBox str\r\n    \r\n    Exit Sub\r\n    \r\nErrH:\r\n    MsgBox \"\u30c6\u30fc\u30d6\u30eb\uff08\u30ea\u30b9\u30c8\uff09\u304c\u3042\u308a\u307e\u305b\u3093\"\r\n\r\nEnd Sub\r\n\u3000\r\n  <\/pre>\n<br \/>\n<h3>\u5b9f\u884c\u7d50\u679c<\/h3>\n<p><a href=\"https:\/\/i0.wp.com\/excelwork.info\/excel\/wp\/wp-content\/uploads\/2016\/07\/listobject_001.jpg?ssl=1\" rel=\"lightbox[5664]\"><img loading=\"lazy\" src=\"https:\/\/i0.wp.com\/excelwork.info\/excel\/wp\/wp-content\/uploads\/2016\/07\/listobject_001.jpg?resize=580%2C483&#038;ssl=1\" alt=\"ListObject \u306e\u4e3b\u306a\u30d7\u30ed\u30d1\u30c6\u30a3\" width=\"580\" height=\"483\" class=\"alignnone size-large wp-image-5665\" srcset=\"https:\/\/i0.wp.com\/excelwork.info\/excel\/wp\/wp-content\/uploads\/2016\/07\/listobject_001.jpg?resize=580%2C483&amp;ssl=1 580w, https:\/\/i0.wp.com\/excelwork.info\/excel\/wp\/wp-content\/uploads\/2016\/07\/listobject_001.jpg?resize=400%2C333&amp;ssl=1 400w, https:\/\/i0.wp.com\/excelwork.info\/excel\/wp\/wp-content\/uploads\/2016\/07\/listobject_001.jpg?w=683&amp;ssl=1 683w\" sizes=\"(max-width: 580px) 100vw, 580px\" data-recalc-dims=\"1\" \/><\/a><\/p>\n<\/div>\n<br \/><br \/>\n","protected":false},"excerpt":{"rendered":"<p>ListObject \u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30d7\u30ed\u30d1\u30c6\u30a3\uff08Range \u30d7\u30ed\u30d1\u30c6\u30a3\u3001Head &#8230; <\/p>\n","protected":false},"author":1,"featured_media":5706,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"amp_status":"","spay_email":"","jetpack_publicize_message":""},"categories":[907],"tags":[914,922,921,920,63,38,908],"jetpack_featured_media_url":"https:\/\/i1.wp.com\/excelwork.info\/excel\/wp\/wp-content\/uploads\/2016\/08\/listobject_001-580x483.jpg?fit=580%2C483&ssl=1","jetpack_publicize_connections":[],"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p4Ye9i-1tm","_links":{"self":[{"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/posts\/5664"}],"collection":[{"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/comments?post=5664"}],"version-history":[{"count":4,"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/posts\/5664\/revisions"}],"predecessor-version":[{"id":5708,"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/posts\/5664\/revisions\/5708"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/media\/5706"}],"wp:attachment":[{"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/media?parent=5664"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/categories?post=5664"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/excelwork.info\/excel\/wp-json\/wp\/v2\/tags?post=5664"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}