{"id":508,"date":"2025-02-25T23:34:19","date_gmt":"2025-02-25T14:34:19","guid":{"rendered":"https:\/\/www.flumen-jp.com\/wordpress\/?p=508"},"modified":"2025-02-25T23:35:01","modified_gmt":"2025-02-25T14:35:01","slug":"chartobjects","status":"publish","type":"post","link":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/2025\/02\/25\/chartobjects\/","title":{"rendered":"ChartObjects \u306e\u7de8\u96c6"},"content":{"rendered":"\n<p>\u3000Excel \u3067\u8907\u6570\u306e\u30b0\u30e9\u30d5\u306e\u69d8\u5f0f\u3092\u7d71\u4e00\u3057\u305f\u3044\u3001\u3068\u3044\u3046\u30cb\u30fc\u30ba\u304c\u7a00\u306b\u3042\u308a\u307e\u3059\u3002<br>\u3000\u3053\u308c\u3092\u30de\u30a6\u30b9\u306e\u64cd\u4f5c\u3067\u884c\u304a\u3046\u3068\u3059\u308b\u3068\u3001\u304b\u306a\u308a\u795e\u7d4c\u3092\u3064\u304b\u3046\u3046\u3048\u6642\u9593\u304c\u304b\u304b\u308a\u307e\u3059\u3002\u3067\u3001\u3053\u308c\u3092 VBA \u3067\u4e00\u6c17\u306b\u51e6\u7406\u3057\u3088\u3046\u3068\u3044\u3046\u306e\u304c\u4eca\u56de\u306e\u30cd\u30bf\u3067\u3059\u3002<\/p>\n\n\n\n<p>\u3000\u5b9f\u969b\u306e\u4f7f\u3063\u305f\u30b3\u30fc\u30c9\u3092\u4ee5\u4e0b\u306b\u4f8b\u793a\u3057\u307e\u3059\u3002<br>\u3000\u4eca\u56de\u306f\u4e3b\u306b\u7b46\u8005\u306e<strong>\u5099\u5fd8\u7528\u306a\u306e\u3067\u89e3\u8aac\u306f\u306a\u3057\uff01<\/strong> \u4e0a\u8a18\u306e\u30b3\u30fc\u30c9\u306e\u4e0d\u660e\u306a\u7b87\u6240\u3001\u3042\u308b\u3044\u306f\u8a72\u5f53\u3059\u308b\u51e6\u7406\u304c\u306a\u3044\u5834\u5408\u306f <a href=\"https:\/\/euc-access-excel-db.com\/00000WPhtml\/Excel2000-obj-model01.png\" target=\"_blank\" rel=\"noreferrer noopener\">Excel \u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u968e\u5c64<\/a>\u3084<a href=\"https:\/\/learn.microsoft.com\/ja-jp\/office\/vba\/api\/excel.chartobject\" target=\"_blank\" rel=\"noreferrer noopener\">\u30aa\u30f3\u30e9\u30a4\u30f3\u30de\u30cb\u30e5\u30a2\u30eb<\/a>\u3068\u683c\u95d8\u3057\u3066\u304f\u3060\u3055\u3044\u3002<br>\u3000\u6c17\u306b\u5165\u308b\u307e\u3067\u4f55\u5ea6\u3067\u3082\u3084\u308a\u76f4\u3057\u304c\u5229\u304f\u306e\u3067\u81c6\u3059\u308b\u3053\u3068\u306a\u304f\u697d\u3092\u3057\u307e\u3057\u3087\u3046\u3002\u305f\u3060\u3057\u3001\u81ea\u4fe1\u306e\u306a\u3044\u51e6\u7406\u3092\u884c\u3046\u5834\u5408\u306f\u4e00\u65e6\u30bb\u30fc\u30d6\u3059\u308b\u3053\u3068\u3092\u304a\u5fd8\u308c\u306a\u304f\u3002<\/p>\n\n\n\n<div class=\"hcb_wrap\"><pre class=\"prism line-numbers lang-ts\" data-lang=\"TypeScript\"><code>Public Sub Unify_Chart(num_s)\n\nWith ChartObjects(&quot;object_name&quot;)\n\n    .Width = 420\n    .Height = 450\n\n    With .Chart\n\n        With .PlotArea\n            .Left = 20\n            .Top = 20\n            .Width = 350\n            .Height = 400\n        End With\n\n        With .Axes(xlCategory)\n            .HasTitle = True\n            .MinimumScale = 0\n            .MaximumScale = 216000\n            .MajorUnit = 43200\n            With .AxisTitle\n                .Caption = &quot;x&quot;\n                .Characters(1, 1).Font.Italic = True\n                .Font.Size = 11\n            End With\n        End With\n\n        With .Axes(xlValue)\n            .HasTitle = True\n            .MinimumScale = -3\n            .MaximumScale = 0\n            .MajorUnit = 0.5\n            .Crosses = xlMinimum\n            .TickLabels.NumberFormat = &quot;0.0&quot;\n            With .AxisTitle\n                .Caption = &quot;y&quot;\n                .Characters(5, 1).Font.Italic = True\n                .Left = 5\n                .Font.Size = 11\n            End With\n        End With\n\n        For itm = 1 To num_s\n            With .SeriesCollection(itm)\n                .MarkerSize = 2\n            End With\n        Next\n\n        For itm = num_s + 1 To .SeriesCollection.Count\n            With .SeriesCollection(itm)\n                .Type = xlXYScatter\n                With .Format.Line\n                    .ForeColor.RGB = RGB(0, 0, 0)\n                    .Weight = 0.25\n                End With\n            End With\n        Next\n\n        With .Legend\n            .Top = 100\n            .Left = 370\n            For itm = .LegendEntries.Count To num_s + 1 Step -1\n                .LegendEntries(itm).Delete\n            Next\n        End With\n\n    End With\nEnd With\n\nEnd Sub<\/code><\/pre><\/div>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3000Excel \u3067\u8907\u6570\u306e\u30b0\u30e9\u30d5\u306e\u69d8\u5f0f\u3092\u7d71\u4e00\u3057\u305f\u3044\u3001\u3068\u3044\u3046\u30cb\u30fc\u30ba\u304c\u7a00\u306b\u3042\u308a\u307e\u3059\u3002\u3000\u3053\u308c\u3092\u30de\u30a6\u30b9\u306e\u64cd\u4f5c\u3067\u884c\u304a\u3046\u3068\u3059\u308b\u3068\u3001\u304b\u306a\u308a\u795e\u7d4c\u3092\u3064\u304b\u3046\u3046\u3048\u6642\u9593\u304c\u304b\u304b\u308a\u307e\u3059\u3002\u3067\u3001\u3053\u308c\u3092 VBA \u3067\u4e00\u6c17\u306b\u51e6\u7406\u3057\u3088\u3046\u3068\u3044\u3046\u306e\u304c\u4eca\u56de\u306e\u30cd\u30bf\u3067\u3059\u3002  [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[46,31],"class_list":["post-508","post","type-post","status-publish","format-standard","hentry","category-it","tag-chartobjects","tag-vba"],"_links":{"self":[{"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/posts\/508","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/comments?post=508"}],"version-history":[{"count":3,"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/posts\/508\/revisions"}],"predecessor-version":[{"id":511,"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/posts\/508\/revisions\/511"}],"wp:attachment":[{"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/media?parent=508"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/categories?post=508"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.flumen-jp.com\/wordpress\/index.php\/wp-json\/wp\/v2\/tags?post=508"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}