Results 1 to 4 of 4

Mail with macro Excel 2010

Threaded View

  1. #1
    Registered User
    Join Date
    12-05-2011
    Location
    Sweden
    MS-Off Ver
    Excel 2010
    Posts
    1

    Mail with macro Excel 2010

    I am very new at writing VB and have managed to send an email with Excel 2003. When I had to upgrade to 2010 so ended this to work. Is there anyone who could help me to make this work in Excel 2010. I have a problem with the format of date and when I save as. The file I'm working on now. Xlsm
    Please i need help!!
    Sub E_Post_Zon_1()
    '
    ' Mail Macro
    ' Macro recorded 2011-07-06 by Santors
            Range("B8").Select
        ActiveCell.FormulaR1C1 = "61000"
        Range("B9").Select
       ' Dim strDate As String
         ActiveSheet.Copy
        strDate = Format(Date, "dd-mm-yy") & " " & Format(Time, "h-mm-ss")
        ActiveWorkbook.SaveAs "Test Stockholm" & ThisWorkbook.Name _
            & " " & strDate & ".xls"
        ActiveWorkbook.SendMail "santors71@gmail.com", _
            "Test Bonus "
        ActiveWorkbook.ChangeFileAccess xlReadOnly
        Kill ActiveWorkbook.FullName
        ActiveWorkbook.Close True
    
    END SUB


    Regards Santors
    Last edited by Santors; 12-08-2011 at 09:15 AM.

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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