Copy worksheet values and formats into another workbook

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am very new to VBA programming.
I have a worksheet (called “Form99â€) that is populated by data entries
placed on another worksheet (called “Data Entryâ€), both in the same workbook.
Data is entered throughout a month. At the end of the month the Form99 is
printed. After the hard copy is secured a button is clicked which clears all
the data from the data entry worksheet (macro), this in turn naturally clears
the values that had been placed in the Form99
What I would like to do is capture the values and formats of the Form99
worksheet and copy them into a new worksheet in a different workbook. For
instance, copy the January Form99 data into a new worksheet in a workbook
called “Achieveâ€. At the end of February copy the February Form99 data into
a new worksheet in that same “Achieve†workbook. At the end of the year I
would have an achieve workbook with a single worksheet for every month of the
year.
I have been successful doing this using a macro which is triggered by a
button in my Data Entry worksheet. The problem I have is that my worksheets
are protected and I can’t execute the macro past the “Enter Password†window
that pops up. I can enter the password but then I have to manually set it
again. I don’t want to give out the password. Is there another way to
accomplish my goal? Is there a way to get over the password problem?
Thank you in advance for your help.
 
Rick,
Search VBA help for "unprotect" and look at its example. Also look at
"protect" from the "See Also". When you get the hang of it you may also want
to lock the module with a password.

Bob L.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top