+ Reply to Thread
Results 1 to 3 of 3

help combining several modules

  1. #1
    Registered User
    Join Date
    03-25-2014
    Location
    Dallas, Texas
    MS-Off Ver
    Excel 2011, Excel 2010
    Posts
    18

    help combining several modules

    So I have mixed, matched, and customized several modules to fit my needs to a point, however - am having trouble tying the pieces together, to run all together.

    Workflow Report Automation (EDIT).xls

    First, I am cleaning up some data within my report:
    Please Login or Register  to view this content.
    Second - I am formatting the content of my report:
    Please Login or Register  to view this content.
    Third - Applying hyperlinks to my items in Column A (I can't figure out how to always apply to the cell if there is a value, and not if it is empty)
    Please Login or Register  to view this content.
    I would like to apply some sort of table-like formatting to this, like a colored header row, and banded rows, but can't figure that out so it maintains alternate shading when the next step engages.

    Fourth - I create individual sheets for all of the teams in my report
    Please Login or Register  to view this content.
    Fifth - I autofit the columns, to prepare for sending the data to identified recipients
    Please Login or Register  to view this content.
    Sixth - This part is becoming very frustrating. I have 2 sets of code, and would like some help in consolidating if possible. My first set, Sub "SendReportSingle" Works great for sending a range to a defined email address in the code, and the Sub "SendReportBatch" works for sending the entire sheets (if it exists) to a coordinated recipient and allows for ad-hoc subject editing.
    I would like to use the range functionality from "SendReportSingle" code, and incorporate that into the "SendReportBatch" code. Any advice on this?

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.

    As you can see - lots of different pieces that I have put together, and could use some help lining it up.

    I would like to have the macro run entirely to the send stage, and then run the send as a separate instance.

    Workbook attached here: Workflow Report Automation (EDIT).xls

    Thanks!

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: help combining several modules

    You seem to have far more problems than are appropriate for a single thread. I will address your stated issue of running subsequent modules in sequence.

    Now that you have developed and can trust the success of individual modules, you can create a master module that simple calls those sub routines in order:

    Please Login or Register  to view this content.

    ...etc.


    Of course you could combine them all into a single module, but there's no real benefit to that, overall, and you've done the work to create the individual trusted modules. So use them.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    03-25-2014
    Location
    Dallas, Texas
    MS-Off Ver
    Excel 2011, Excel 2010
    Posts
    18

    Re: help combining several modules

    You reminded me of a question I had while compiling these - am I using any sort of conflicting codes?

    Since I have compiled and customized from multiple sources, I haven't stuck to any sort of formats, and the portion I recorded and edited myself (probably very obvious to a trained eye) has no real structure as far as I can tell.

    The main reason I have multiple modules is cause I don't know how to insert additional macros into a routine (but yes, I have come to trust them!)

    I'll run the code you suggested, thanks!


    Sent from my iPad using Tapatalk

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. "Private object modules cannot be used in public object modules...."
    By 6StringJazzer in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-01-2013, 04:07 PM
  2. Replies: 6
    Last Post: 04-21-2011, 01:12 PM
  3. [SOLVED] Public, Private, Event modules, Forms modules,,,
    By Jim May in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 10-31-2005, 12:05 AM
  4. Combining Modules
    By Carlton Patterson in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 06-28-2005, 06:05 AM
  5. Basic question - modules and class modules - what's the difference?
    By Mark Stephens in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 05-08-2005, 07:08 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1