Hey folks,
Another head scratcher here.
Have a button on a form which is supposed to open an Excel (2010, xlsm) spreadsheet. It did open once or twice where it was visible to the user. But now, even tho it does launch Excel, as seen in the task manager, it doesn't show the spreadsheet on screen. So if I try again, I get another instance of Excel showing in the task manager
When it did open visibly, closing the spreadsheet then closed out the Excel application and was no longer a process in task manager. But now, I have to manually end the process or they just keep piling up.
Here is the button code:
Any suggestion?
Thanks,
Vic
Another head scratcher here.
Have a button on a form which is supposed to open an Excel (2010, xlsm) spreadsheet. It did open once or twice where it was visible to the user. But now, even tho it does launch Excel, as seen in the task manager, it doesn't show the spreadsheet on screen. So if I try again, I get another instance of Excel showing in the task manager
When it did open visibly, closing the spreadsheet then closed out the Excel application and was no longer a process in task manager. But now, I have to manually end the process or they just keep piling up.
Here is the button code:
Code:
Private Sub btnTalHdrs_Click()
Dim xl As Object
Dim wb As Workbook
Dim fso As Object
Dim fn As String
Set fso = CreateObject("Scripting.FileSystemObject")
fn = "F:\DBMS\Membership\Membership\TalReqColHdrs.xlsm"
If fso.FileExists(fn) = True Then
Set xl = CreateObject("Excel.Application")
Set wb = xl.Workbooks.Open(fn)
Else
Beep
MsgBox "Talen header template file does not exist. Please notify programmer.", vbOKOnly, "Can't Find File"
DoCmd.Close acForm, Me.Name, acSaveNo
End If
Set fso = Nothing
End Sub
Any suggestion?
Thanks,
Vic