Corrected but it still doesn't work
jobsave = InputBox("Please enter TIME SHEET file name to save",
> " Process Technology", "" & "C:\Time Sheets\ " + jobnumber + " " +
> jobemployee + " " + (Jobdate))
"Oldjay" wrote:
>
>
> I get this error at "ActiveWorkbook.SaveCopyAs Filename:=jobsave"
>
>
> Private Sub CommandButton4_Click() 'Save time sheet
> Dim jobname As String
> Dim jobemployee As String
> Dim Jobdate As String
> Dim jobnumber As String
> Dim jobsave As String
>
>
> Jobdate = Range("C10").Value ' set date format to mm-dd-yy
>
> Jobdate = Month(Jobdate) & "-" & Day(Jobdate) & "-" & Year(Jobdate)
> jobname = Range("D6")
> jobemployee = Range("E3")
> jobnumber = Range("D4")
>
> jobsave = InputBox("Please enter TIME SHEET file name to save",
> " Process Technology", "" & "C:Time Sheets\ " + jobnumber + " " +
> jobemployee + " " + (Jobdate))
> If jobsave = "" Then
>
> Range("A1").Select
> Range("D3").Select
>
> Else
> ActiveWorkbook.SaveCopyAs Filename:=jobsave
>
> On Error GoTo ErrorHandler:
> Range("A1").Select
> Range("D3").Select
> End If
> ErrorHandler:
>
> Range("A1").Select
> Range("D3").Select
>
> End Sub
>
> oldjay
|