excel - Error when deleting SHAPES -


a piece of code (to delete shapes in sheet) started throw error

"object not support property or method"

and highlights row if shp.type = msoautoshape then part of big code continuously update, code below not part of cycle, if, etc. reason?

dim shp shape each shp in actws.shapes                                                             if shp.type = msoautoshape shp.delete next shp 

your code works me. there shapes, using. can run this:

public sub ale()  dim shp shape  each shp in activesheet.shapes     if shp.type = msoautoshape         debug.print shp.name         shp.delete     end if next shp  end sub 

and share last result immediate window before error comes? also, can confirm on line of new code error comes?


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

javascript - Get parameter of GET request -

javascript - Twitter Bootstrap - how to add some more margin between tooltip popup and element -