+ Reply to Thread
Results 1 to 4 of 4

Can a Macro generate a report?

  1. #1
    Registered User
    Join Date
    08-15-2008
    Location
    UK
    Posts
    2

    Can a Macro generate a report?

    I've just written my very first macro and I need a little bit of help....

    My company receives huge excel spreadsheets from our clients containing lots of customer information. One of the fields is email addresses, my job is to make sure these email addresses are formatted correctly (replacing things like , for . and .couk. for .co.uk) .

    This takes ages, as there are hundreds/thousands of emails, so I have written a very basic macro to speed this up, and it works really well.

    Is there a way that I can get the macro to generate some kind of report after/while running, to either show me a list of errors it has corrected or at least the total number of errors corrected?

    thanks in advance

  2. #2
    Registered User
    Join Date
    07-18-2008
    Location
    India
    Posts
    68

    Can a Macro generate a report?

    Hi,

    You can write a macro to generate the report.
    Accept all the corrections you have made in an array and then print it.

    e.g.

    dim myarr(100) as string

    for each correction made
    Please Login or Register  to view this content.
    Last edited by VBA Noob; 08-16-2008 at 01:35 AM.

  3. #3
    Registered User
    Join Date
    08-15-2008
    Location
    UK
    Posts
    2
    thanks for the reply, I'm probably going to need a bit more help (I am a COMPLETE newbie at this) ...

    my macro is listed below, whereabouts do I add the code you provided?

    Please Login or Register  to view this content.
    thanks again

  4. #4
    Registered User
    Join Date
    07-18-2008
    Location
    India
    Posts
    68

    Can a Macro generate a report?

    Please see the attached file.

    I have made some changes to your code.
    The report will be generated leaving 2 rows after your data ends.
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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