![]() |
Removing objects without unmerging cells
When I use this code on a worksheet that doesn't contain
clip art to delete, I get the error message "This operation will cause some merged cells to unmerge. Do you want to continue". How can I use this code to delete unwanted clip art objects without unmerging any cells? Set myDocument = Worksheets(1) myDocument.Shapes.SelectAll Selection.Delete |
Removing objects without unmerging cells
one way:
Dim myDocument As Worksheet Set myDocument = Worksheets(1) With myDocument.Pictures If .Count 0 Then .Delete End With In article , wrote: When I use this code on a worksheet that doesn't contain clip art to delete, I get the error message "This operation will cause some merged cells to unmerge. Do you want to continue". How can I use this code to delete unwanted clip art objects without unmerging any cells? Set myDocument = Worksheets(1) myDocument.Shapes.SelectAll Selection.Delete |
Removing objects without unmerging cells
Thanks!...Works good!
-----Original Message----- one way: Dim myDocument As Worksheet Set myDocument = Worksheets(1) With myDocument.Pictures If .Count 0 Then .Delete End With In article , wrote: When I use this code on a worksheet that doesn't contain clip art to delete, I get the error message "This operation will cause some merged cells to unmerge. Do you want to continue". How can I use this code to delete unwanted clip art objects without unmerging any cells? Set myDocument = Worksheets(1) myDocument.Shapes.SelectAll Selection.Delete . |
All times are GMT +1. The time now is 08:49 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com