实现细目_自动删除Excel细目表

实现细目

With the pivot table Show Details feature in Excel, a new sheet is inserted when you double-click on the value cell in a pivot table.

使用Excel中的数据透视表“显示详细信息”功能,双击数据透视表中的值单元格会插入一个新工作表。

It's a great feature for drilling into the details, but you can end up with lots of extra sheets in your workbook.

这是深入研究细节的一项重要功能,但最终可能会在工作簿中增加很多额外的工作表。

showdetails03

Usually, you don't want to save the sheets, so you manually delete them before you close the file.

通常,您不想保存工作表,因此在关闭文件之前手动将其删除。

自动命名工作表 (Automatically Name the Sheets)

With event code on the pivot table's worksheet, and in the workbook module, you can add a prefix – XShow_ – when these detail sheets are created.

使用数据透视表的工作表上以及工作簿模块中的事件代码,可以在创建这些明细表时添加前缀– XShow_ –。

showdetails06

That prefix should make the sheets easier to find and delete.

该前缀应使工作表更易于查找和删除。

自动删除工作表 (Automatically Delete the Sheets)

To make the cleanup task even easier, you can use event code to prompt you to delete those sheet when you're closing the workbook.

为了使清理任务更加容易,您可以使用事件代码在关闭工作簿时提示您删除那些工作表。

showdetails04

If you click Yes, all the sheets with the XShow_ prefix are deleted. Then, click Save, to save the tidied up version of the workbook.

如果单击“是”,则所有带有XShow_前缀的图纸都将被删除。 然后,单击“保存”以保存整理后的工作簿版本。

请参阅明细表代码 (See the Drilldown Sheet Code)

For detailed instructions on adding the drilldown sheet naming and deleting code, visit the Excel Pivot Table Drilldown page on the Contextures website.

有关添加明细表命名和删除代码的详细说明,请访问Contextures网站上的Excel Pivot Table Drilldown页面。

下载样本明细文件 (Download the Sample Drilldown File)

To see how the event code names the sheets, and deletes them when closing, you can download the Pivot Table Drilldown sample file. ________________

若要查看事件代码如何命名工作表,并在关闭时将其删除,可以下载“ 数据透视表明细”样本文件 。 ________________

翻译自: https://contexturesblog.com/archives/2011/06/10/delete-excel-drilldown-sheets-automatically/

实现细目

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值