简体   繁体   English

宏以删除表中的最后一行

[英]Macro to delete last row in table

I have a table in Excel filled with data. 我在Excel中有一个充满数据的表。

Is there any way to create a macro that deletes the last row in the table and automatically updates the new table range to NOT include that row? 有什么方法可以创建一个宏,该宏将删除表中的最后一行并自动更新新表范围以不包括该行?

Seems this suited: 似乎适合:

select a cell within it and run Selection.End(xlDown).Delete Shift:=xlUp 选择其中的一个单元格并运行Selection.End(xlDown).Delete Shift:=xlUp

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM