Vba Sheet Clear Contents. Clear contents is a method in vba which is used to delete or remove the values which are stored in the cells provided to it, this method makes the cell range empty and it is used with the range property to access the specified cell range, the example to use this method is as follows range(“a1:b2”).clearcontents this method will clear the contents of cells from a1 to b2. Press the f5 key to run the code.
In the cell range, we provide the cell range which we want to clear. We just need to enclose the name of the worksheets in parentheses and quotes as well as the range of cells. Please click file > save as > browse.