• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

VBA experts, I need guidance on VBA code to do a few things.

jherrera

New Member
I have been looking for a VBA subroutine to add it into a "main routine." My program will always have three sheets: the "start" sheet (permanent sheet), "a," and "b" or "x" and "z" (only two scenarios). What I want to accomplish is this:
1. The main VBA routine is running, then
2. If sheet "a" exists, then insert in sheet "b," cell $D$1, a formula that refers to the "start" sheet (=start!$F$1).
3. If "a" does not exist but "x" exists, then insert in sheet "z," cell $D$1, a formula that refers to the start sheet (=start!$F$2).
4. Do nothing if sheets "a" and "x" do not exist.
4. Then, continue running and finishing the main routine.
Thank you for your help!
 
Back
Top