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

asked on

Covert Excel Formula to Workbook

Hi Experts,

Can someone show me how I would go about applying the following excel code to a workbook. At the moment it applies to a worksheet called 2 Bull Up 3 Bear Dwn 2 Bull Up, but I would like to be able to apply globally on all worksheets.

Sub zolumn()
   With Sheets("2 Bull Up 3 Bear Dwn 2 Bull Up")
      .Range("B2", .Cells(.Rows.Count, "B").End(xlUp)).ClearContents
   End With
End Sub

Cheers
ASKER CERTIFIED SOLUTION
Avatar of zorvek (Kevin Jones)
zorvek (Kevin Jones)
Flag of United States of America 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
Avatar of cpatte7372

ASKER

Kev,

Thanks man......
Kev/Experts,

Can someone please also convert the following globally across the workbook as Kevin did above?

Sub Part1()
    Dim lastrow As Long
   
    lastrow = Sheets("Stocks").Range("A" & Rows.Count).End(xlUp).Row
   
    Sheets("Stocks").Range("A1:A" & lastrow).Copy _
    Sheets("Four Lows Five High").Range("B1")
End Sub

Cheers
Cheers