I have a xlsm file that i open with a href from a html file. The xlsm file have some code in the open workbook so is opens a xlm file. It works fine when i double click the xlsm file, but when it is open through a href link the xlsm file opens but it does not open the xml file?
Can someone help with this?
Dim strname As String
Dim strpath As String
Dim oExcel As Excel.Application
Dim oWX As Workbook
Set oExcel = New Excel.Application
Application.Visible = False
Application.WindowState = xlMinimized
Application.ScreenUpdating = False
strname = Replace(ThisWorkbook.Name, ".xlsm", ".xml")
strpath = ThisWorkbook.Path & "/"
Set oWX = Workbooks.OpenXML(strpath & strname)
Application.Visible = True
Application.WindowState = xlMaximized
Application.ScreenUpdating = True