LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Mail Single sheet as HTML(HTM) file


Hello everyone!
I have a working macro, which sends a single sheet from the workbook t
the following mail receipients. E-mail addresses are specified in th
sheet with customer list.
I need an upgrade.
I want to send not an .xls file, but a .htm file.

What changes should I do? How to make excel export single sheet an
save it as htm file, then e-mail it?

P.S. How to remove an Outlook Express warning "Would you like to sen
the message?" I have to press SEND every time I e-mail something.

Great thanks to all who are able to help.

Macro code is:

Sub Mail_ActiveSheet()
For a = Cells(4, 3).Value To Cells(4, 4).Value (
Rows(a).Select
Selection.Copy
Rows("1:1").Select
Application.ActiveSheet.Paste
If Cells(1, 15).Value < "" Then
Sheets("kl sar orig").Select
d = Cells(1, 15).Value
Sheets("sheet_to_mail").Select
b = Cells(15, 5).Value
c = Cells(15, 6).Value
Dim wb As Workbook
Dim strdate As String
strdate = Format(Now, "dd-mm-yy h-mm-ss")
Application.ScreenUpdating = False
ActiveSheet.Copy
Set wb = ActiveWorkbook
With wb
.SaveAs "Vartotojui " & ThisWorkbook.Name _
& " " & strdate & a & ".xls"
Cells.Select
Application.CutCopyMode = False
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone
SkipBlanks _
:=False, Transpose:=False

.Sendmail d, _
& b & " iki " & c
.ChangeFileAccess xlReadOnly
Kill .FullName
.Close True
End With
Else
End If
Sheets("kl sar orig").Select
Application.ScreenUpdating = True
Next a
End Su

--
arg
-----------------------------------------------------------------------
argi's Profile: http://www.excelforum.com/member.php...fo&userid=2432
View this thread: http://www.excelforum.com/showthread.php?threadid=37930

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I e-mail one Excel sheet to arrive NOT in HTML southwest worker Excel Discussion (Misc queries) 1 June 30th 06 09:43 PM
Pasting HTML into a single cell tg550 Excel Discussion (Misc queries) 4 May 31st 06 01:28 PM
Save single sheet from XLS file as HTML Tomasz Klim Excel Discussion (Misc queries) 2 July 29th 05 03:55 PM
Mail a singel sheet i an xls file. Kirsten Excel Discussion (Misc queries) 1 June 8th 05 01:25 PM
Can you save a single sheet directly to a new file defensiveone Excel Worksheet Functions 2 May 13th 05 08:10 PM


All times are GMT +1. The time now is 02:06 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"