Jo-Milk

VBA code to remove checkboxes Excel

Nov 25th, 2021
674
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //VBA code to remove checkboxes from copy paste formatting super useful in Excel
  2. Sub sbRemoveCheckboxesinActiveSheet_OLEControls()
  3.  
  4. For Each shp In ActiveSheet.Shapes
  5. If shp.Type = msoOLEControlObject Then
  6.         If shp.OLEFormat.Object.OLEType = 2 Then shp.Delete
  7.     End If
  8. Next
  9. End Sub
RAW Paste Data