{"id":416,"date":"2023-10-29T17:51:23","date_gmt":"2023-10-29T17:51:23","guid":{"rendered":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/"},"modified":"2023-12-10T11:47:16","modified_gmt":"2023-12-10T11:47:16","slug":"%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1","status":"publish","type":"page","link":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/","title":{"rendered":"\u5982\u4f55\u4f7f\u7528vba\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f"},"content":{"rendered":"<div class=\"excel-\" id=\"excel-3738838843\"><script type=\"text\/javascript\">\r\n\tatOptions = {\r\n\t\t'key' : 'c1158f160081d6540a8409e6925dab94',\r\n\t\t'format' : 'iframe',\r\n\t\t'height' : 250,\r\n\t\t'width' : 300,\r\n\t\t'params' : {}\r\n\t};\r\n<\/script>\r\n<script type=\"text\/javascript\" src=\"\/\/www.highperformanceformat.com\/c1158f160081d6540a8409e6925dab94\/invoke.js\"><\/script><\/div> <p>\u4e00\u65e6\u5f00\u59cb\u5b66\u4e60 VBA\uff0c\u60a8\u53ef\u4ee5\u505a\u7684\u6700\u9177\u7684\u4e8b\u60c5\u4e4b\u4e00\u5c31\u662f\u7f16\u5199 VBA \u4ee3\u7801\u4ee5\u5c06\u65b0\u5de5\u4f5c\u8868\u63d2\u5165\u5230\u5de5\u4f5c\u7c3f\u4e2d\u3002<\/p><p>\u55ef\uff0c\u5df2\u7ecf\u6709\u63d2\u5165\u65b0\u5de5\u4f5c\u8868\u7684\u5feb\u6377\u952e\uff0c\u6216\u8005\u4e5f\u53ef\u4ee5\u4f7f\u7528\u666e\u901a\u9009\u9879\uff0c\u4f46\u4f7f\u7528 VBA \u4ee3\u7801\u7684\u597d\u5904\u662f\uff0c\u53ea\u9700\u5355\u51fb\u4e00\u4e0b\u5373\u53ef\u6dfb\u52a0\u591a\u4e2a\u5de5\u4f5c\u8868\uff0c\u8fd8\u53ef\u4ee5\u5b9a\u4e49\u8981\u6dfb\u52a0\u7684\u4f4d\u7f6e\u5b83\u3002<\/p><p>\u4e3a\u6b64\uff0c\u60a8\u9700\u8981\u4f7f\u7528 Sheets.Add \u65b9\u6cd5\uff0c\u5728\u672c\u6587\u4e2d\uff0c\u6211\u4eec\u5c06\u5b66\u4e60\u5982\u4f55\u4f7f\u7528\u5b83\u5728\u5de5\u4f5c\u7c3f\u4e2d\u6dfb\u52a0\u4e00\u4e2a\u6216\u591a\u4e2a\u5de5\u4f5c\u8868\u3002<\/p><h2 class=\"wp-block-heading\"> Sheets.Add \u65b9\u6cd5<\/h2><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sheets.Add ([Before], [After], [Count], [Type])<\/code><\/pre><ul><li>\u4e4b\u524d\uff1a\u5728\u5de5\u4f5c\u8868\u4e4b\u524d\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\u3002<\/li><li>\u4e4b\u540e\uff1a\u5c06\u65b0\u5de5\u4f5c\u8868\u6dfb\u52a0\u5230\u5de5\u4f5c\u8868\u4e4b\u524d\u3002<\/li><li>\u8ba1\u6570\uff1a\u8981\u6dfb\u52a0\u7684\u9875\u6570\u3002<\/li><li>\u7c7b\u578b\uff1a\u60a8\u8981\u6dfb\u52a0\u7684\u5de5\u4f5c\u8868\u7c7b\u578b ( <a href=\"https:\/\/docs.microsoft.com\/en-us\/office\/vba\/api\/excel.xlsheettype\" target=\"_blank\" rel=\"noreferrer noopener\" aria-label=\"LINK (opens in a new tab)\">\u94fe\u63a5<\/a>)<\/li><\/ul><h2 class=\"wp-block-heading\">\u7f16\u5199 VBA \u4ee3\u7801\u4ee5\u5c06\u65b0\u5de5\u4f5c\u8868\u6dfb\u52a0\u5230\u5de5\u4f5c\u7c3f<\/h2><p>\u6253\u5f00 Visual Basic \u7f16\u8f91\u5668\u5e76\u6309\u7167\u4ee5\u4e0b\u6b65\u9aa4\u64cd\u4f5c\u3002<\/p><ul><li>\u9996\u5148\uff0c\u60a8\u9700\u8981\u8fdb\u5165Sheets.Add\u65b9\u6cd5\u3002<\/li><li>\u63a5\u4e0b\u6765\uff0c\u60a8\u9700\u8981\u5b9a\u4e49\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\u7684\u4f4d\u7f6e\uff08\u4e4b\u524d\u6216\u4e4b\u540e\uff09\u3002<\/li><li>\u63a5\u4e0b\u6765\u662f\u8f93\u5165\u5de5\u4f5c\u8868\u7684\u6570\u91cf\u3002<\/li><li>\u6700\u7ec8\uff0c\u7eb8\u5f20\u7684\u7c7b\u578b\u3002 <\/li><\/ul><div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-47897\" src=\"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png\" sizes=\"auto, \" srcset=\"\" alt=\"\u6dfb\u52a0\u5de5\u4f5c\u8868\u6dfb\u52a0 VBA \u65b9\u6cd5\" width=\"597\" height=\"161\"><\/figure><\/div><h2 class=\"wp-block-heading\">\u4f7f\u7528 VBA \u4ee3\u7801\u5728\u5de5\u4f5c\u7c3f\u4e2d\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\u7684\u4e0d\u540c\u65b9\u6cd5<\/h2><p>\u4ee5\u4e0b\u662f\u5c06\u65b0\u5de5\u4f5c\u8868\u6dfb\u52a0\u5230\u5de5\u4f5c\u7c3f\u7684\u4e0d\u540c\u65b9\u6cd5\uff1a<\/p><h3 class=\"wp-block-heading\"> 1. \u6dfb\u52a0\u5355\u5f20\u8868<\/h3><p>\u8981\u6dfb\u52a0\u5355\u4e2a\u5de5\u4f5c\u8868\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528\u4e0b\u9762\u7684\u4ee3\u7801\uff0c\u5176\u4e2d\u672a\u6307\u5b9a\u4efb\u4f55\u53c2\u6570\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub SheetAddExample1() ActiveWorkbook.Sheets.Add End Sub<\/code><\/pre><p>\u6b64\u4ee3\u7801\u544a\u8bc9 Excel \u5728\u6d3b\u52a8\u5de5\u4f5c\u7c3f\u4e2d\u6dfb\u52a0\u4e00\u4e2a\u5de5\u4f5c\u8868\uff0c\u4f46\u7531\u4e8e\u6ca1\u6709\u53c2\u6570\uff0c\u5b83\u5c06\u4f7f\u7528\u9ed8\u8ba4\u503c\u5e76\u5728\u6d3b\u52a8\u5de5\u4f5c\u8868\u4e4b\u524d\u6dfb\u52a0\u4e00\u4e2a\u5de5\u4f5c\u8868 (xlWorksheet)\u3002<\/p><p>\u8fd9\u662f\u53e6\u4e00\u79cd\u7f16\u5199\u65b9\u6cd5\uff0c\u8bf7\u53c2\u9605\u4e0b\u9762\u7684\u4ee3\u7801\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub SheetAddExample2() Sheets.Add End Sub<\/code><\/pre><p>\u7531\u4e8e\u60a8\u5df2\u7ecf\u4f4d\u4e8e\u6d3b\u52a8\u5de5\u4f5c\u7c3f\u4e2d\uff0c\u56e0\u6b64\u60a8\u8fd8\u53ef\u4ee5\u4f7f\u7528\u4e0b\u9762\u7684\u4ee3\u7801\u3002\u4ed6\u4e5f\u505a\u540c\u6837\u7684\u4e8b\u60c5\u3002<\/p><h3 class=\"wp-block-heading\"> 2. \u6dfb\u52a0\u591a\u5f20\u8868<\/h3><p>\u8981\u4e00\u6b21\u6dfb\u52a0\u591a\u4e2a\u5de5\u4f5c\u8868\uff0c\u53ea\u9700\u5c06 COUNT \u53c2\u6570\u8bbe\u7f6e\u4e3a\u8981\u6dfb\u52a0\u7684\u5de5\u4f5c\u8868\u6570\u91cf\u5373\u53ef\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub AddSheets3() Sheets.Add Count:=5 End Sub<\/code><\/pre><p>\u73b0\u5728\u60a8\u8bbe\u7f6e\u7684\u5de5\u4f5c\u8868\u6570\u91cf\u4e3a 5\uff0c\u56e0\u6b64\u5f53\u60a8\u8fd0\u884c\u6b64\u4ee3\u7801\u65f6\uff0c\u5b83\u4f1a\u7acb\u5373\u5c06\u4e94\u4e2a\u65b0\u5de5\u4f5c\u8868\u6dfb\u52a0\u5230\u5de5\u4f5c\u7c3f\u4e2d\u3002<\/p><h3 class=\"wp-block-heading\"> 3. \u6dfb\u52a0\u4e00\u4e2a\u5e26\u6709\u540d\u79f0\u7684\u5de5\u4f5c\u8868<\/h3><p>\u5982\u679c\u60a8\u60f3\u5728\u6dfb\u52a0\u5de5\u4f5c\u8868\u540e\u91cd\u547d\u540d\u8be5\u5de5\u4f5c\u8868\uff0c\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u4ee3\u7801\uff1a<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub AddNewSheetswithNameExample1() Sheets.Add.Name = \"myNewSHeet\" End Sub<\/code><\/pre><p>\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u6211\u4eec\u4f7f\u7528\u4e86\u540d\u79f0\uff08 <a href=\"https:\/\/docs.microsoft.com\/en-us\/office\/vba\/api\/excel.names\">LINK<\/a> \uff09\u5bf9\u8c61\u6765\u5e2e\u52a9\u60a8\u6307\u5b9a\u5de5\u4f5c\u8868\u7684\u540d\u79f0\u3002<\/p><h3 class=\"wp-block-heading\"> 4. \u6dfb\u52a0\u4e00\u4e2a\u5177\u6709\u5355\u5143\u683c\u540d\u79f0\u7684\u5de5\u4f5c\u8868<\/h3><p>\u60a8\u8fd8\u53ef\u4ee5\u4ece\u5355\u5143\u683c\u4e2d\u83b7\u53d6\u8981\u7528\u4f5c\u5de5\u4f5c\u8868\u540d\u79f0\u7684\u503c\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub AddNewSheetswithNameExample2() Sheets.Add.Name = Range(\"A1\") End Sub<\/code><\/pre><p>\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u5355\u5143\u683c A1 \u7528\u4e8e\u83b7\u53d6\u65b0\u5de5\u4f5c\u8868\u7684\u540d\u79f0\u3002<\/p><h3 class=\"wp-block-heading\"> 5. \u5728\u7279\u5b9a\u5de5\u4f5c\u8868\u4e4b\u540e\/\u4e4b\u524d\u6dfb\u52a0\u5de5\u4f5c\u8868<\/h3><p>\u7531\u4e8e\u8fd9\u4e9b\u53c2\u6570\u5df2\u5b58\u5728\u4e8e Sheets.Add \u4e2d\uff0c\u60a8\u53ef\u4ee5\u5728\u5176\u4e2d\u6307\u5b9a\u8981\u5728\u4e4b\u524d\u6216\u4e4b\u540e\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\u7684\u5de5\u4f5c\u8868\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub AddSheetsExample5() Sheets.Add Before:=Worksheets(\"mySheet\") Sheets.Add After:=Worksheets(\"mySheet\") End Sub<\/code><\/pre><p>\u73b0\u5728\uff0c\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u60a8\u5728 Sheet.Add \u65b9\u6cd5\u4e2d\u7684\u53c2\u6570\u4e4b\u524d\u548c\u4e4b\u540e\u4f7f\u7528\u4e86\u4e24\u884c\u4ee3\u7801\u3002\u56e0\u6b64\uff0c\u5f53\u60a8\u8fd0\u884c\u6b64\u4ee3\u7801\u65f6\uff0c\u5b83\u4f1a\u6dfb\u52a0\u4e24\u5f20\u8868\uff0c\u4e00\u5f20\u5728\u201cmySheet\u201d\u4e4b\u524d\uff0c\u4e00\u5f20\u5728\u201cmySheet\u201d\u4e4b\u540e\u3002<\/p><h3 class=\"wp-block-heading\"> 6. \u5728\u5f00\u5934\u6dfb\u52a0\u4e00\u4e2a\u65b0\u5de5\u4f5c\u8868<\/h3><p>\u4f7f\u7528 before using \u53c2\u6570\uff0c\u60a8\u8fd8\u53ef\u4ee5\u5c06\u5de5\u4f5c\u8868\u6dfb\u52a0\u5230\u5de5\u4f5c\u7c3f\u4e2d\u5de5\u4f5c\u8868\u7684\u5f00\u5934\u3002<\/p><p>\u6240\u4ee5\u57fa\u672c\u4e0a\u6211\u4eec\u8981\u505a\u7684\u662f\u6307\u5b9a\u5de5\u4f5c\u8868\u7f16\u53f7\u800c\u4e0d\u662f\u5de5\u4f5c\u8868\u540d\u79f0\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub AddSheetsExample6() Sheets.Add Before:=Sheets(1) End Sub<\/code><\/pre><p>\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u60a8\u4f7f\u7528\u4e86\u5de5\u4f5c\u8868\u7f16\u53f7 (1)\uff0c\u5b83\u544a\u8bc9 VBA \u5728\u6240\u6709\u5de5\u4f5c\u8868\u4e2d\u7b2c\u4e00\u4e2a\u4f4d\u7f6e\u7684\u5de5\u4f5c\u8868\u4e4b\u524d\u6dfb\u52a0\u8be5\u5de5\u4f5c\u8868\u3002\u8fd9\u6837\u5b83\u603b\u662f\u4f1a\u5728\u5f00\u5934\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\u3002<\/p><h3 class=\"wp-block-heading\"> 7. \u5728\u672b\u5c3e\u6dfb\u52a0\u4e00\u4e2a\u65b0\u5de5\u4f5c\u8868\uff08\u5728\u6700\u540e\u4e00\u4e2a\u5de5\u4f5c\u8868\u4e4b\u540e\uff09<\/h3><p>\u8981\u5728\u672b\u5c3e\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\uff0c\u60a8\u9700\u8981\u4ee5\u4e0d\u540c\u7684\u65b9\u5f0f\u7f16\u5199\u4ee3\u7801\u3002\u56e0\u6b64\uff0c\u4e3a\u6b64\u60a8\u9700\u8981\u77e5\u9053\u5de5\u4f5c\u7c3f\u4e2d\u6709\u591a\u5c11\u5f20\u5de5\u4f5c\u8868\uff0c\u4ee5\u4fbf\u60a8\u53ef\u4ee5\u5728\u672b\u5c3e\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic line-numbers\" lang=\"visual-basic\">Sub AddSheetsExample8() Sheets.Add After:=Sheets(Sheets.Count) End Sub<\/code><\/pre><p>\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0cSheet.Count \u8fd4\u56de\u5de5\u4f5c\u7c3f\u4e2d\u7684\u5de5\u4f5c\u8868\u6570\u91cf\uff0c\u5e76\u4e14\u7531\u4e8e\u60a8\u8bbe\u7f6e\u4e86 after \u53c2\u6570\uff0c\u56e0\u6b64\u5b83\u4f1a\u5728\u5de5\u4f5c\u7c3f\u4e2d\u7684\u6700\u540e\u4e00\u4e2a\u5de5\u4f5c\u8868\u4e4b\u540e\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\u3002<\/p><h3 class=\"wp-block-heading\"> 8. \u6dfb\u52a0\u591a\u4e2a\u5de5\u4f5c\u8868\u5e76\u4f7f\u7528\u8303\u56f4\u540d\u79f0<\/h3><p>\u4ee5\u4e0b\u4ee3\u7801\u5bf9 A1:A7 \u8303\u56f4\u5185\u7684\u884c\u8fdb\u884c\u8ba1\u6570\u3002\u4e4b\u540e\uff0c\u5b83\u5faa\u73af\u6839\u636e\u8303\u56f4\u8ba1\u6570\u6dfb\u52a0\u5de5\u4f5c\u8868\uff0c\u5e76\u5728\u6dfb\u52a0\u65f6\u4f7f\u7528\u8303\u56f4\u503c\u6765\u547d\u540d\u5de5\u4f5c\u8868\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub AddSheetsExample9() Dim sheets_count As Integer Dim sheet_name As String Dim i As Integer sheet_count = Range(\"A1:A7\").Rows.Count For i = 1 To sheet_count sheet_name = Sheets(\"mySheet\").Range(\"A1:A7\").Cells(i, 1).Value Worksheets.Add().Name = sheet_name Next i End Sub<\/code><\/pre><p>\u4f46\u5bf9\u4e8e\u4e0a\u9762\u7684\u4ee3\u7801\uff0c\u60a8\u8981\u6dfb\u52a0\u7684\u5de5\u4f5c\u8868\u7684\u540d\u79f0\u53ef\u80fd\u5df2\u7ecf\u5b58\u5728\uff0c\u6216\u8005\u540d\u79f0\u8303\u56f4\u4e2d\u6709\u4e00\u4e2a\u7a7a\u5355\u5143\u683c\u3002<\/p><p>\u5728\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0c\u60a8\u9700\u8981\u7f16\u5199\u4e00\u6bb5\u4ee3\u7801\u6765\u68c0\u67e5\u540c\u540d\u7684\u5de5\u4f5c\u8868\u662f\u5426\u5df2\u5b58\u5728\uff0c\u4ee5\u53ca\u8981\u83b7\u53d6\u5de5\u4f5c\u8868\u540d\u79f0\u7684\u5355\u5143\u683c\u662f\u5426\u4e3a\u7a7a\u3002<\/p><p>\u5982\u679c\u4ec5\u6ee1\u8db3\u8fd9\u4e24\u4e2a\u6761\u4ef6\uff0c\u5219\u5e94\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868\u3002\u6211\u5206\u4e24\u6b65\u6765\u8bf4\uff1a<\/p><p><strong>\u9996\u5148<\/strong>\uff0c\u60a8\u9700\u8981\u7f16\u5199\u4e00\u4e2a<a href=\"https:\/\/exceladvisor.org\/cn\/\u7528\u6237\u5b9a\u4e49\u51fd\u65702\/\">Excel\u7528\u6237\u5b9a\u4e49\u51fd\u6570<\/a>\u6765\u68c0\u67e5\u662f\u5426\u5b58\u5728\u540c\u540d\u7684\u5de5\u4f5c\u8868\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Function SheetCheck(sheet_name As String) As Boolean Dim ws As Worksheet SheetCheck = False For Each ws In ThisWorkbook.Worksheets If ws.Name = sheet_name Then SheetCheck = True End If Next End Function<\/code><\/pre><p>\u5176\u6b21\uff0c\u60a8\u9700\u8981\u4f7f\u7528\u6b64\u51fd\u6570\u7f16\u5199\u4e00\u4e9b\u4ee3\u7801\uff0c\u5e76\u4e14\u8be5\u4ee3\u7801\u8fd8\u9700\u8981\u68c0\u67e5\u540d\u79f0\u5355\u5143\u683c\u662f\u5426\u4e3a\u7a7a\u3002<\/p><pre class=\"wp-block-code\"> <code class=\"language-visual-basic\" lang=\"visual-basic\">Sub AddMultipleSheet2() Dim sheets_count As Integer Dim sheet_name As String Dim i As Integer sheet_count = Range(\"A1:A7\").Rows.Count For i = 1 To sheet_count sheet_name = Sheets(\"mySheet\").Range(\"A1:A10\").Cells(i, 1).Value If SheetCheck(sheet_name) = False And sheet_name &lt;&gt; \"\" Then Worksheets.Add().Name = sheet_name End If Next i End Sub<\/code><\/pre><p>\u73b0\u5728\uff0c\u5728\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u60a8\u4f7f\u7528\u4e86<a href=\"https:\/\/exceladvisor.org\/cn\/\u5982\u679c-2\/\" target=\"_blank\" rel=\"noreferrer noopener\" aria-label=\"VBA IF Statement (opens in a new tab)\">VBA IF \u8bed\u53e5<\/a>\uff0c\u5e76\u4e14\u5728\u6b64\u8bed\u53e5\u4e2d\uff0c\u60a8\u6709\u5de5\u4f5c\u8868\u68c0\u67e5\u529f\u80fd\uff0c\u8be5\u529f\u80fd\u68c0\u67e5\u5de5\u4f5c\u8868\u540d\u79f0\uff0c\u7136\u540e\u60a8\u6709\u4e00\u4e2a\u6761\u4ef6\u6765\u68c0\u67e5\u540d\u79f0\u5355\u5143\u683c\u662f\u5426\u5177\u6709\u7a7a\u503c\u3002<\/p><p> <strong><a href=\"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/11\/add-sheet-using-vba.zip\" target=\"_blank\" rel=\"noreferrer noopener nofollow\" aria-label=\"Sample File (opens in a new tab)\">\u793a\u4f8b\u6587\u4ef6<\/a><\/strong><\/p><div class=\"gb-container gb-container-4db6181c gb-container-mt\"><a class=\"gb-button gb-button-c5897111 gb-button-text gb-button-mt-button\" href=\"https:\/\/exceladvisor.org\/cn\/\u7ef4\u5df4\/\">\u4ec0\u4e48\u662fVBA<\/a><h2 class=\"gb-headline gb-headline-665e5f6b gb-headline-text gb-headline-mt-heading\">\u76f8\u5173\u6559\u7a0b<\/h2><div class=\"gb-grid-wrapper gb-grid-wrapper-a20baf7c gb-grid-wrapper-mt-grid\"><div class=\"gb-grid-column gb-grid-column-65ddf67e\"><div class=\"gb-container gb-container-65ddf67e\"><ul><li><a href=\"https:\/\/exceladvisor.org\/cn\/\u900f\u660e\u7eb8\/\">\u5728 Excel \u4e2d\u4f7f\u7528 VBA \u6e05\u9664\u6574\u4e2a\u5de5\u4f5c\u8868<\/a><\/li><li><a href=\"https:\/\/exceladvisor.org\/cn\/\u590d\u5370\u8868\/\">\u4f7f\u7528 VBA \u5728 Excel \u4e2d\u590d\u5236\u548c\u79fb\u52a8\u5de5\u4f5c\u8868<\/a><\/li><li><a href=\"https:\/\/exceladvisor.org\/cn\/\u6570\u53f6\u5b50\/\">\u5728 Excel \u4e2d\u4f7f\u7528 VBA \u8ba1\u7b97 COUNT \u4e2a\u5de5\u4f5c\u8868<\/a><\/li><\/ul><\/div><\/div><div class=\"gb-grid-column gb-grid-column-50067b57\"><div class=\"gb-container gb-container-50067b57\"><ul><li> <a href=\"https:\/\/exceladvisor.org\/cn\/\u5de5\u4f5c\u8868-1\/\">VBA \u5de5\u4f5c\u8868\u5bf9\u8c61<\/a><\/li><li><a href=\"https:\/\/exceladvisor.org\/cn\/\u6fc0\u6d3b\u8868\/\">\u4f7f\u7528 VBA \u6fc0\u6d3b\u5de5\u4f5c\u8868<\/a><\/li><li><a href=\"https:\/\/exceladvisor.org\/cn\/\u63a7\u5236\u8868\u5b58\u5728\/\">VBA \u68c0\u67e5\u5de5\u4f5c\u8868\u662f\u5426\u5b58\u5728<\/a><\/li><\/ul><\/div><\/div><\/div><\/div>","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"ub_ctt_via":"","footnotes":""},"class_list":["post-416","page","type-page","status-publish","hentry"],"featured_image_src":null,"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.4 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u5982\u4f55\u4f7f\u7528VBA\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f<\/title>\n<meta name=\"description\" content=\"\u6709\u4e00\u4e2a\u540d\u4e3a SHEETS.ADD \u7684\u7279\u5b9a\u65b9\u6cd5\u3002\u8fd9\u4e2a\u65b9\u6cd5\u57fa\u672c\u4e0a\u5c31\u50cf\u6211\u4eec\u7684\u4e00\u4e2a\u51fd\u6570\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/exceladvisor.org\/cn\/\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868-1\/\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u5982\u4f55\u4f7f\u7528VBA\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f\" \/>\n<meta property=\"og:description\" content=\"\u6709\u4e00\u4e2a\u540d\u4e3a SHEETS.ADD \u7684\u7279\u5b9a\u65b9\u6cd5\u3002\u8fd9\u4e2a\u65b9\u6cd5\u57fa\u672c\u4e0a\u5c31\u50cf\u6211\u4eec\u7684\u4e00\u4e2a\u51fd\u6570\" \/>\n<meta property=\"og:url\" content=\"https:\/\/exceladvisor.org\/cn\/\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868-1\/\" \/>\n<meta property=\"og:site_name\" content=\"Excel Advisor\" \/>\n<meta property=\"article:modified_time\" content=\"2023-12-10T11:47:16+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/\",\"url\":\"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/\",\"name\":\"\u5982\u4f55\u4f7f\u7528VBA\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f\",\"isPartOf\":{\"@id\":\"https:\/\/exceladvisor.org\/cn\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png\",\"datePublished\":\"2023-10-29T17:51:23+00:00\",\"dateModified\":\"2023-12-10T11:47:16+00:00\",\"description\":\"\u6709\u4e00\u4e2a\u540d\u4e3a SHEETS.ADD \u7684\u7279\u5b9a\u65b9\u6cd5\u3002\u8fd9\u4e2a\u65b9\u6cd5\u57fa\u672c\u4e0a\u5c31\u50cf\u6211\u4eec\u7684\u4e00\u4e2a\u51fd\u6570\",\"breadcrumb\":{\"@id\":\"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#primaryimage\",\"url\":\"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png\",\"contentUrl\":\"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u5bb6\",\"item\":\"https:\/\/exceladvisor.org\/cn\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u5982\u4f55\u4f7f\u7528vba\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/exceladvisor.org\/cn\/#website\",\"url\":\"https:\/\/exceladvisor.org\/cn\/\",\"name\":\"Excel Advisor\",\"description\":\"\u60a8\u7684\u6570\u636e\u7edf\u6cbb\u7ec8\u6781\u6307\u5357\",\"publisher\":{\"@id\":\"https:\/\/exceladvisor.org\/cn\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/exceladvisor.org\/cn\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/exceladvisor.org\/cn\/#organization\",\"name\":\"Excel Advisor\",\"url\":\"https:\/\/exceladvisor.org\/cn\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/exceladvisor.org\/cn\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/exceladvisor.org\/cn\/wp-content\/uploads\/2023\/12\/exceladvisor.org_.png\",\"contentUrl\":\"https:\/\/exceladvisor.org\/cn\/wp-content\/uploads\/2023\/12\/exceladvisor.org_.png\",\"width\":105,\"height\":36,\"caption\":\"Excel Advisor\"},\"image\":{\"@id\":\"https:\/\/exceladvisor.org\/cn\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u5982\u4f55\u4f7f\u7528VBA\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f","description":"\u6709\u4e00\u4e2a\u540d\u4e3a SHEETS.ADD \u7684\u7279\u5b9a\u65b9\u6cd5\u3002\u8fd9\u4e2a\u65b9\u6cd5\u57fa\u672c\u4e0a\u5c31\u50cf\u6211\u4eec\u7684\u4e00\u4e2a\u51fd\u6570","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:\/\/exceladvisor.org\/cn\/\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868-1\/","og_locale":"zh_CN","og_type":"article","og_title":"\u5982\u4f55\u4f7f\u7528VBA\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f","og_description":"\u6709\u4e00\u4e2a\u540d\u4e3a SHEETS.ADD \u7684\u7279\u5b9a\u65b9\u6cd5\u3002\u8fd9\u4e2a\u65b9\u6cd5\u57fa\u672c\u4e0a\u5c31\u50cf\u6211\u4eec\u7684\u4e00\u4e2a\u51fd\u6570","og_url":"https:\/\/exceladvisor.org\/cn\/\u6dfb\u52a0\u65b0\u5de5\u4f5c\u8868-1\/","og_site_name":"Excel Advisor","article_modified_time":"2023-12-10T11:47:16+00:00","og_image":[{"url":"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png","type":"","width":"","height":""}],"twitter_card":"summary_large_image","twitter_misc":{"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"1 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/","url":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/","name":"\u5982\u4f55\u4f7f\u7528VBA\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f","isPartOf":{"@id":"https:\/\/exceladvisor.org\/cn\/#website"},"primaryImageOfPage":{"@id":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#primaryimage"},"image":{"@id":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#primaryimage"},"thumbnailUrl":"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png","datePublished":"2023-10-29T17:51:23+00:00","dateModified":"2023-12-10T11:47:16+00:00","description":"\u6709\u4e00\u4e2a\u540d\u4e3a SHEETS.ADD \u7684\u7279\u5b9a\u65b9\u6cd5\u3002\u8fd9\u4e2a\u65b9\u6cd5\u57fa\u672c\u4e0a\u5c31\u50cf\u6211\u4eec\u7684\u4e00\u4e2a\u51fd\u6570","breadcrumb":{"@id":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/"]}]},{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#primaryimage","url":"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png","contentUrl":"https:\/\/exceladvisor.org\/wp-content\/uploads\/2023\/08\/ajouter-des-feuilles-ajouter-une-methode-vba.png"},{"@type":"BreadcrumbList","@id":"https:\/\/exceladvisor.org\/cn\/%e6%b7%bb%e5%8a%a0%e6%96%b0%e5%b7%a5%e4%bd%9c%e8%a1%a8-1\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u5bb6","item":"https:\/\/exceladvisor.org\/cn\/"},{"@type":"ListItem","position":2,"name":"\u5982\u4f55\u4f7f\u7528vba\u4ee3\u7801\u521b\u5efa\u65b0\u5de5\u4f5c\u8868\uff1f"}]},{"@type":"WebSite","@id":"https:\/\/exceladvisor.org\/cn\/#website","url":"https:\/\/exceladvisor.org\/cn\/","name":"Excel Advisor","description":"\u60a8\u7684\u6570\u636e\u7edf\u6cbb\u7ec8\u6781\u6307\u5357","publisher":{"@id":"https:\/\/exceladvisor.org\/cn\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/exceladvisor.org\/cn\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"zh-Hans"},{"@type":"Organization","@id":"https:\/\/exceladvisor.org\/cn\/#organization","name":"Excel Advisor","url":"https:\/\/exceladvisor.org\/cn\/","logo":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/exceladvisor.org\/cn\/#\/schema\/logo\/image\/","url":"https:\/\/exceladvisor.org\/cn\/wp-content\/uploads\/2023\/12\/exceladvisor.org_.png","contentUrl":"https:\/\/exceladvisor.org\/cn\/wp-content\/uploads\/2023\/12\/exceladvisor.org_.png","width":105,"height":36,"caption":"Excel Advisor"},"image":{"@id":"https:\/\/exceladvisor.org\/cn\/#\/schema\/logo\/image\/"}}]}},"yoast_meta":{"yoast_wpseo_title":"","yoast_wpseo_metadesc":"","yoast_wpseo_canonical":""},"_links":{"self":[{"href":"https:\/\/exceladvisor.org\/cn\/wp-json\/wp\/v2\/pages\/416","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/exceladvisor.org\/cn\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/exceladvisor.org\/cn\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/exceladvisor.org\/cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/exceladvisor.org\/cn\/wp-json\/wp\/v2\/comments?post=416"}],"version-history":[{"count":1,"href":"https:\/\/exceladvisor.org\/cn\/wp-json\/wp\/v2\/pages\/416\/revisions"}],"predecessor-version":[{"id":1056,"href":"https:\/\/exceladvisor.org\/cn\/wp-json\/wp\/v2\/pages\/416\/revisions\/1056"}],"wp:attachment":[{"href":"https:\/\/exceladvisor.org\/cn\/wp-json\/wp\/v2\/media?parent=416"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}