Link to home
Start Free TrialLog in
Avatar of cpatte7372
cpatte7372Flag for United Kingdom of Great Britain and Northern Ireland

asked on

Clear column

Hello Experts,

Can someone please let me know if there are quick ways clear the contents within a column.

Basically, I'm constantly deleting/clearing the contents in a column and inserting new data from a new sheet.

So for example, in the attached spreadsheet I would clear all the symbols in column A sheet 1 and then go to sheet 2 copy the stock symbols in one of the columns and paste it into column A in sheet 1. I continue doing this until I've gone through all the symbols in sheet 2.

As you can imagine this can become quite a laborious task.

If you can help that would be greatly appreciate.

Thanks in advance.

Cheers

Carlton
delete-column.xlsx
Avatar of Rory Archibald
Rory Archibald
Flag of United Kingdom of Great Britain and Northern Ireland image

Select A2, press Ctrl+Shift+down arrow, then delete?
Avatar of cpatte7372

ASKER

Rory,

Thanks responding. I know my request makes me sound a little lazy but I was wondering if may be a macro could fulfill my request?
ASKER CERTIFIED SOLUTION
Avatar of Rory Archibald
Rory Archibald
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Rory,

Thanks again mate for responding.

I'm very new to excel programming. Can you please tell me how to add your code to excel?

Cheers

Carlton
Rory,

I just need to know how to insert the formula/commands you specified.

Cheers
1. Press Alt+f11 to open the Visual Basic Editor.
2. Locate your workbook in the Project Explorer window (top left usually), right-click it and choose Insert-Module.
3. Paste the code above into the blank code window that appears.
4. Save your file as a macro-enabled workbook (xlsm extension rather than xlsx)

You can then run the macro by pressing Alt+f8 to bring up the macros dialog box. In that dialog, you can also select the macro name from the list, click the Options... button and assign a shortcut key combination (such as Ctrl+Q) so that you can run it more easily.
Rory,

That worked a treat.

Cheers mate.
This question has been classified as abandoned and is being closed as part of the Cleanup Program. See my comment at the end of the question for more details.