I have an Excel sheet to collect data from various users. There is code in the workbook to email the file back to me. I want to have the file save using the value of a specific cell (Location number) prior to being sent.
I get Runtime error 1004 saying the couldn't be accessed with the code below. The error asks if the folder exists, readonly, that the name contains no special characters, etc.
If I change the file name and type it out it will save and doesn't need the full path. I run into the problem when I try to use the Lst variable. I had the same problem when I separated the Range Value and file name and tried Lst & Fle as the name. Fle = "_IssuesForm.xls".
I feel like I'm really close but missing something, Thanks in advance for your help!
I get Runtime error 1004 saying the couldn't be accessed with the code below. The error asks if the folder exists, readonly, that the name contains no special characters, etc.
If I change the file name and type it out it will save and doesn't need the full path. I run into the problem when I try to use the Lst variable. I had the same problem when I separated the Range Value and file name and tried Lst & Fle as the name. Fle = "_IssuesForm.xls".
I feel like I'm really close but missing something, Thanks in advance for your help!
Code:
Dim Lst As String
Lst = Range("G19").Value & "_IssuesForm.xls"
ActiveWorkbook.SaveAs Filename:= _
Lst _
, FileFormat:=xlNormal, Password:="", WriteResPassword:="", _
ReadOnlyRecommended:=False, CreateBackup:=False