> > -- How would you identify which cells on the main sheet contain the updated
> > data for each specific program? I DON'T KNOW - I'm honestly not sure how to go about this...
What I mean is: when you look at the main sheet, how do you know which data
cells go with which program? For instance, is the program name listed down
Column A, and the data for that program is in H of the same row? How many
cells need to be updated from the main sheet, and how do you know which ones
they are?
The biggest thing to remember about any routine like this is that it can
almost always be broken into smaller increments. When you take it one step
at a time, it's not so very intimidating. You do have to be able to
identify the process you would use without a macro, because your macro is
going to have to do that same process. And what we know intuitively when we
look at our work has to be spelled out in detail for in the code.
Try this:
-- Create a new Excel workbook and give it some more worksheets.
-- Put the macro below into a module. (With Excel open, press ALT+F11 -
this opens the Visual Basic Editor (VBE). Go to Insert >> Module. Copy
everything below from "Sub UpdateAllSheets()" to "End Sub".)
-- Back in Excel, press ALT+F8 to bring up a list of macros. Choose
"UpdateAllSheets" and see what happens. (The macro sets the Zoom percentage
for every sheet except Sheet1.)
-- Go back to the VBE and look at the code, and see if you can understand
what the code is doing.
Ed
Sub UpdateAllSheets()
Dim objWkbk As Workbook
Dim objWksh As Worksheet
Dim strZm As String
Dim intZm As Integer
Set objWkbk = ActiveWorkbook
strZm = InputBox("What zoom?")
If strZm = "" Then GoTo ExitHere
intZm = strZm
For Each objWksh In objWkbk.Sheets
If objWksh.Name <> "Sheet1" Then
objWksh.Activate
ActiveWindow.Zoom = intZm
objWksh.Range("A1").Select
End If
Next objWksh
objWkbk.Sheets("Sheet1").Activate
ExitHere:
End Sub
> see below - thanks
>
[quoted text clipped - 23 lines]
> > > Bear with me because this is to new to me, but I know there has to be a
> > > better way to handle this workbook.