D
Dion
I use the following code to open a Monarch Application
from Access, a Project file in Monarch, and create an
Excel spreadsheet with the results from the filter set in
Monarch. The problem I have is when it creates the
spreadsheet, it creates a version 2.1 spreadsheet rather
than a later version. I am using Office Pro 2000. Any
ideas on how (or even if) I could go about setting the
code to create a newer version of a spreadsheet? Any help
is appreciated.
Public Function MonarchRun()
On Error GoTo Err_monarchrun
Set MonarchObj = CreateObject("Monarch32")
MonarchObj.SetProjectFile ("G:\GROUPS\EVERYONE\Dormant
Accounts\DDADormant.prj")
MonarchObj.ExportTable ("G:\GROUPS\EVERYONE\Dormant
Accounts\DDADormants.xls")
MonarchObj.CloseAllDocuments
MonarchObj.SetProjectFile ("G:\GROUPS\EVERYONE\Dormant
Accounts\SAVDormant.prj")
MonarchObj.ExportTable ("G:\GROUPS\EVERYONE\Dormant
Accounts\SAVDormants.xls")
MonarchObj.CloseAllDocuments
MonarchObj.Exit
Set MonarchObj = Nothing
Exit_monarchrun:
Exit Function
Err_monarchrun:
MsgBox Err.Description
Resume Exit_monarchrun
from Access, a Project file in Monarch, and create an
Excel spreadsheet with the results from the filter set in
Monarch. The problem I have is when it creates the
spreadsheet, it creates a version 2.1 spreadsheet rather
than a later version. I am using Office Pro 2000. Any
ideas on how (or even if) I could go about setting the
code to create a newer version of a spreadsheet? Any help
is appreciated.
Public Function MonarchRun()
On Error GoTo Err_monarchrun
Set MonarchObj = CreateObject("Monarch32")
MonarchObj.SetProjectFile ("G:\GROUPS\EVERYONE\Dormant
Accounts\DDADormant.prj")
MonarchObj.ExportTable ("G:\GROUPS\EVERYONE\Dormant
Accounts\DDADormants.xls")
MonarchObj.CloseAllDocuments
MonarchObj.SetProjectFile ("G:\GROUPS\EVERYONE\Dormant
Accounts\SAVDormant.prj")
MonarchObj.ExportTable ("G:\GROUPS\EVERYONE\Dormant
Accounts\SAVDormants.xls")
MonarchObj.CloseAllDocuments
MonarchObj.Exit
Set MonarchObj = Nothing
Exit_monarchrun:
Exit Function
Err_monarchrun:
MsgBox Err.Description
Resume Exit_monarchrun