+ Reply to Thread
Results 1 to 2 of 2

Copy excel table to mail message but ignore cells with zero values

  1. #1
    Registered User
    Join Date
    10-03-2012
    Location
    Lisbon
    MS-Off Ver
    Excel 2016
    Posts
    7

    Copy excel table to mail message but ignore cells with zero values

    Hello,
    I have a table generated with different formulas that I want to copy to a mail message. After research I came up with this code:

    Please Login or Register  to view this content.
    My problem is that the range "X2:Z200" could have cells with zeros as result of formulas that shouldn't be copied to the message. Could anyone help find the way to prevent copying the cells wit zero values ?

    Regards

  2. #2
    Forum Guru
    Join Date
    07-25-2011
    Location
    Florida
    MS-Off Ver
    Excel 2003
    Posts
    9,643

    Re: Copy excel table to mail message but ignore cells with zero values

    Consider changing your formulas to not generate a zero e.g.

    =IF(your formula = 0, "", your formula)
    Surround your VBA code with CODE tags e.g.;
    [CODE]your VBA code here[/CODE]
    The # button in the forum editor will apply CODE tags around your selected text.

+ 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. Copy Range and Paste only Values (ignore blank cells)
    By ksayet in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-18-2015, 04:37 PM
  2. [SOLVED] Copy from Lotus note body in mail to excel cells.
    By abjac in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 11-15-2014, 05:46 AM
  3. Replies: 0
    Last Post: 11-07-2014, 02:08 PM
  4. Need to Copy Outlook 2010 Mail message to Excel 2010
    By pradeepdeepu_001 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-08-2012, 11:35 PM
  5. Extracting mail message(outlook) table in the message body
    By andywsw in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-12-2012, 10:14 PM
  6. If a Table is in the body of a mail.. want to extract the same in to the excel cells
    By anchuri_chaitanya in forum Outlook Programming / VBA / Macros
    Replies: 0
    Last Post: 06-27-2011, 05:38 AM
  7. [SOLVED] How do I get a pivot table to ignore some values
    By Neostand in forum Excel General
    Replies: 3
    Last Post: 06-14-2006, 08:34 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