Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Dim objApp As Object '1-2-3 application
Dim objDoc As Object '1-2-3 workbook
Dim blnOpen As Boolean 'Flag if 1-2-3 already running
'Check if 1-2-3 is already running
On Error Resume Next
Set objDoc = GetObject("", "Lotus123.Workbook")
'Restore error handling. Errors from here on
'are reported up the call stack
On Error Goto 0
If objDoc Is Nothing Then
'1-2-3 is not running, open it by creating a new document
Set objDoc = CreateObject("Lotus123.Workbook")
Else
'1-2-3 is running, set the flag
blnOpen = True
End If
'Get the reference to the application object
Set objApp = objDoc.Parent
'It's optional to make it visible
If Not blnOpen Then
objApp.Visible = True
End If
'Open the 1-2-3 workbook
Set objDoc = objApp.OpenDocument( _
"xyz.123", "x:\mypath")
'Save the workbook as .xls
objDoc.SaveAs "xyz.xls", "X:\mypath", "Microsoft Excel 97-2000 Workbook (XLS)"
'Close the doc
If blnOpen Then
'1-2-3 was running, just close the new doc
objDoc.Close
Else
'We started 1-2-3 so close it
'There should be one untitled doc
'and the new doc open
'In 1-2-3, closing the last doc also closes the app.
'If you close all docs then use Quit on the app there's a run-time error
For Each objDoc in objApp.Documents
objDoc.Close False
Next
End If
'Release object references
Set objDoc = Nothing
Set objApp = Nothing