Hi Friends ,
i am trying to save my sheet ( Temp) as based on a cell value , there is a date in Cell J2, I need each time when sheet is getting emailed through Outlook , it should be send as per the name in Cell J2, Currently i have set it to the Current date , however i need this as per Cell Value , below is my code
please review and share the feedback where i am incorrect the above code .
thank you .
i am trying to save my sheet ( Temp) as based on a cell value , there is a date in Cell J2, I need each time when sheet is getting emailed through Outlook , it should be send as per the name in Cell J2, Currently i have set it to the Current date , however i need this as per Cell Value , below is my code
Code:
Dim TempFilePath As String
Dim TempFileName As String
'Save the new workbook/Mail it/Delete it
TempFilePath = Environ$("temp") & "\"
TempFileName = Sheets("Do-Not-Change").Range("J2").Text
ThisWorkbook.SaveAs Filename:=TempFilePath & "\" & TempFileName
please review and share the feedback where i am incorrect the above code .
thank you .