I am attempting to educate myself with VBA and write useful code.
I am familiar with recording macros and some formulas. I can nest functions in certain formulas, etc...
I bought the Excel Bible by Walkenbach. It's not really useful when it comes to VBA. I learned the basics(I think)...Application, Object, Property, Method.
I am waiting on another book that is exclusively for writing code. So far between recording macros, Google, and forums like this one, I am able to cut, insert and create a new sheet.
Problem is I can't get it all to work at the same time! Here is my code:
![]()
Please Login or Register to view this content.
Don't laugh. This got me very excited when they worked. I can get them to run on their own but how does one separate these actions and keep them in the same subroutine? I was also researching ways to "Call" using another sub. At least that way I can create a command button and assign that code to it. Then when I tried to call multiple subs it gave me an error. Heck, I get an error on the first sub but it works perfectly.
I suppose my question is, how do I separate the code commands (cut and paste a range / create a new sheet; cut and paste headers) to all run under the same sub? Then I need to pull out their respective sales codes, all the data in that row, and paste that all to new worksheets/workbooks. I don't want someone to do it for me. I tried that and I learn nothing except how much of an amateur I am when I try to interpert the 8000 lines of script that took an Excel MVP 1 minute to write. How can I get the 2 separate subs in my post to run together at the same time? Would anyone be willing to hold my hand and walk me through this process as I learn and explain to me what I need to do and did? I would really appreciate it and would most definitely pay it forward. Thanks!
Bookmarks