How to fix the Error to send the excel sheet and same pasted on email body [on hold] ...
How would a mousetrap for use in space work?
Most bit efficient text communication method?
Maximum summed powersets with non-adjacent items
Should I use a zero-interest credit card for a large one-time purchase?
Where are Serre’s lectures at Collège de France to be found?
How come Sam didn't become Lord of Horn Hill?
When the Haste spell ends on a creature, do attackers have advantage against that creature?
Using et al. for a last / senior author rather than for a first author
Compare a given version number in the form major.minor.build.patch and see if one is less than the other
Did MS DOS itself ever use blinking text?
How do I find out the mythology and history of my Fortress?
Is there a kind of relay only consumes power when switching?
Why are both D and D# fitting into my E minor key?
How do I stop a creek from eroding my steep embankment?
If my PI received research grants from a company to be able to pay my postdoc salary, did I have a potential conflict interest too?
What would be the ideal power source for a cybernetic eye?
How to react to hostile behavior from a senior developer?
When a candle burns, why does the top of wick glow if bottom of flame is hottest?
Do I really need to have a message in a novel to appeal to readers?
Is the Standard Deduction better than Itemized when both are the same amount?
Has negative voting ever been officially implemented in elections, or seriously proposed, or even studied?
Circuit to "zoom in" on mV fluctuations of a DC signal?
Can a new player join a group only when a new campaign starts?
Extracting terms with certain heads in a function
How to fix the Error to send the excel sheet and same pasted on email body [on hold]
Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Text boxes in excel disappear when worksheet is copied into new workbookExcel macro copy same entries once in another sheet paperHow can I edit this macro to loop through the results?Spreadsheet for Daily Equipment HoursInserting Autotext (or Quickpart) into Word (2013) on the basis of a Boolean value from Access (2013)Sheet name dynamically assigned from a cell valueNot Inserting new records instead it updates the last record in Ms access vbaExcel VBA: Creating Hyperlinks Type MismatchWhat is causing Excel 2010 to consume over 3GB of memory during a custom sort operation?command button execute copy and paste of worksheets into a new workbook and then automatically runs a macro in the new worksheets
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}
Sub Send_Email_With_snapshot()
Dim sh As Worksheet
Set sh = ThisWorkbook.Sheets("Summary")
ActiveWorkbook.RefreshAll
Dim lr As Integer
lr = sh.Range("A" & Application.Rows.Count).End(xlUp).Row
sh.Range("D1:AS274").Select
Dim fso As Object
Dim ts As Object
Dim TempFile As String
Dim TempWB As Workbook
TempFile = Environ$("temp") & "/" & Format(Now, "dd-mm-yy h-mm-ss") & ".html"
'Copy the range and create a new workbook to past the data in
sh.Range("D1:AS274").Select
Set TempWB = Workbooks.Add(1)
With TempWB.Sheets(1)
.Cells(1).PasteSpecial Paste:=8
.Cells(1).PasteSpecial xlPasteValues, , False, False
.Cells(1).PasteSpecial xlPasteFormats, , False, False
.Cells(1).Select
Application.CutCopyMode = False
On Error Resume Next
.DrawingObjects.Visible = True
.DrawingObjects.Delete
On Error GoTo 0
End With
With Selection.Parent.MailEnvelope.Item
.to = "Test@Test.com"
.cc = ""
.Subject = sh.Range("A3").Value
.send
End With
Application.DisplayAlerts = False
ThisWorkbook.Save
Application.DisplayAlerts = False
Application.Quit
End Sub
microsoft-excel vba
New contributor
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
put on hold as unclear what you're asking by Máté Juhász, DavidPostill♦ 14 hours ago
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
add a comment |
Sub Send_Email_With_snapshot()
Dim sh As Worksheet
Set sh = ThisWorkbook.Sheets("Summary")
ActiveWorkbook.RefreshAll
Dim lr As Integer
lr = sh.Range("A" & Application.Rows.Count).End(xlUp).Row
sh.Range("D1:AS274").Select
Dim fso As Object
Dim ts As Object
Dim TempFile As String
Dim TempWB As Workbook
TempFile = Environ$("temp") & "/" & Format(Now, "dd-mm-yy h-mm-ss") & ".html"
'Copy the range and create a new workbook to past the data in
sh.Range("D1:AS274").Select
Set TempWB = Workbooks.Add(1)
With TempWB.Sheets(1)
.Cells(1).PasteSpecial Paste:=8
.Cells(1).PasteSpecial xlPasteValues, , False, False
.Cells(1).PasteSpecial xlPasteFormats, , False, False
.Cells(1).Select
Application.CutCopyMode = False
On Error Resume Next
.DrawingObjects.Visible = True
.DrawingObjects.Delete
On Error GoTo 0
End With
With Selection.Parent.MailEnvelope.Item
.to = "Test@Test.com"
.cc = ""
.Subject = sh.Range("A3").Value
.send
End With
Application.DisplayAlerts = False
ThisWorkbook.Save
Application.DisplayAlerts = False
Application.Quit
End Sub
microsoft-excel vba
New contributor
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
put on hold as unclear what you're asking by Máté Juhász, DavidPostill♦ 14 hours ago
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
1
What is the error?
– Máté Juhász
15 hours ago
HI I m Unable to run this code getting error 1004 i like to send the same on email and same file as a attachment without macro or paste values also Request you to please help and fix these vba code I m using 2016 excel
– Shaf3067
14 hours ago
add a comment |
Sub Send_Email_With_snapshot()
Dim sh As Worksheet
Set sh = ThisWorkbook.Sheets("Summary")
ActiveWorkbook.RefreshAll
Dim lr As Integer
lr = sh.Range("A" & Application.Rows.Count).End(xlUp).Row
sh.Range("D1:AS274").Select
Dim fso As Object
Dim ts As Object
Dim TempFile As String
Dim TempWB As Workbook
TempFile = Environ$("temp") & "/" & Format(Now, "dd-mm-yy h-mm-ss") & ".html"
'Copy the range and create a new workbook to past the data in
sh.Range("D1:AS274").Select
Set TempWB = Workbooks.Add(1)
With TempWB.Sheets(1)
.Cells(1).PasteSpecial Paste:=8
.Cells(1).PasteSpecial xlPasteValues, , False, False
.Cells(1).PasteSpecial xlPasteFormats, , False, False
.Cells(1).Select
Application.CutCopyMode = False
On Error Resume Next
.DrawingObjects.Visible = True
.DrawingObjects.Delete
On Error GoTo 0
End With
With Selection.Parent.MailEnvelope.Item
.to = "Test@Test.com"
.cc = ""
.Subject = sh.Range("A3").Value
.send
End With
Application.DisplayAlerts = False
ThisWorkbook.Save
Application.DisplayAlerts = False
Application.Quit
End Sub
microsoft-excel vba
New contributor
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Sub Send_Email_With_snapshot()
Dim sh As Worksheet
Set sh = ThisWorkbook.Sheets("Summary")
ActiveWorkbook.RefreshAll
Dim lr As Integer
lr = sh.Range("A" & Application.Rows.Count).End(xlUp).Row
sh.Range("D1:AS274").Select
Dim fso As Object
Dim ts As Object
Dim TempFile As String
Dim TempWB As Workbook
TempFile = Environ$("temp") & "/" & Format(Now, "dd-mm-yy h-mm-ss") & ".html"
'Copy the range and create a new workbook to past the data in
sh.Range("D1:AS274").Select
Set TempWB = Workbooks.Add(1)
With TempWB.Sheets(1)
.Cells(1).PasteSpecial Paste:=8
.Cells(1).PasteSpecial xlPasteValues, , False, False
.Cells(1).PasteSpecial xlPasteFormats, , False, False
.Cells(1).Select
Application.CutCopyMode = False
On Error Resume Next
.DrawingObjects.Visible = True
.DrawingObjects.Delete
On Error GoTo 0
End With
With Selection.Parent.MailEnvelope.Item
.to = "Test@Test.com"
.cc = ""
.Subject = sh.Range("A3").Value
.send
End With
Application.DisplayAlerts = False
ThisWorkbook.Save
Application.DisplayAlerts = False
Application.Quit
End Sub
microsoft-excel vba
microsoft-excel vba
New contributor
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
edited 14 hours ago
bummi
1,50331422
1,50331422
New contributor
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
asked 15 hours ago
Shaf3067Shaf3067
1
1
New contributor
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Shaf3067 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
put on hold as unclear what you're asking by Máté Juhász, DavidPostill♦ 14 hours ago
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
put on hold as unclear what you're asking by Máté Juhász, DavidPostill♦ 14 hours ago
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
1
What is the error?
– Máté Juhász
15 hours ago
HI I m Unable to run this code getting error 1004 i like to send the same on email and same file as a attachment without macro or paste values also Request you to please help and fix these vba code I m using 2016 excel
– Shaf3067
14 hours ago
add a comment |
1
What is the error?
– Máté Juhász
15 hours ago
HI I m Unable to run this code getting error 1004 i like to send the same on email and same file as a attachment without macro or paste values also Request you to please help and fix these vba code I m using 2016 excel
– Shaf3067
14 hours ago
1
1
What is the error?
– Máté Juhász
15 hours ago
What is the error?
– Máté Juhász
15 hours ago
HI I m Unable to run this code getting error 1004 i like to send the same on email and same file as a attachment without macro or paste values also Request you to please help and fix these vba code I m using 2016 excel
– Shaf3067
14 hours ago
HI I m Unable to run this code getting error 1004 i like to send the same on email and same file as a attachment without macro or paste values also Request you to please help and fix these vba code I m using 2016 excel
– Shaf3067
14 hours ago
add a comment |
0
active
oldest
votes
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
1
What is the error?
– Máté Juhász
15 hours ago
HI I m Unable to run this code getting error 1004 i like to send the same on email and same file as a attachment without macro or paste values also Request you to please help and fix these vba code I m using 2016 excel
– Shaf3067
14 hours ago