sfatz
Structural
- Jul 14, 2004
- 8
I have a Visual Basic front end to a Mathcad 12 worksheet. The VB app binds user input to variables in the MathCAD worksheet and gets the results without too much trouble.
The problem I have is when the user is done with the app. I can close the MathCAD worksheet, but I can't seem to close the MathCAD application's process. I have tried setting it to Nothing, but it still remains. What is the code to completly close the application?
-----
'declaration statements
Public MC As Mathcad.Application
Public WK As Mathcad.Worksheets
Public WS As Mathcad.Worksheet
'code to cleanup
WS.Close SaveOption:=mcDiscardChanges
Set WS = Nothing
Set WK = Nothing
Set MC = Nothing
-----
The problem I have is when the user is done with the app. I can close the MathCAD worksheet, but I can't seem to close the MathCAD application's process. I have tried setting it to Nothing, but it still remains. What is the code to completly close the application?
-----
'declaration statements
Public MC As Mathcad.Application
Public WK As Mathcad.Worksheets
Public WS As Mathcad.Worksheet
'code to cleanup
WS.Close SaveOption:=mcDiscardChanges
Set WS = Nothing
Set WK = Nothing
Set MC = Nothing
-----