Close Command after running MATLAB function in EXCEL VBA
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hi,
I'm finding a close command after running a M file in EXCEL VBA.
Because I got a alert message like "Microsoft Office Excel is waiting for another application to complete on OLE action" after running a M file in Excel VBA.
Do you have any idea about the close MATLAB application command in VBA?
Dim MatLab As Object
Dim Result As String
Set MatLab = CreateObject("MatLab.desktop.Application")
Result = MatLab.Execute("cd('C:\Documents and Settings\M02043\Desktop\MATLAB Interface Test')")
Result = MatLab.Execute("f_ann")
End Sub
Thanks a lot in advance.
1 comentario
Kaustubha Govind
el 19 de Jul. de 2011
Try
MatLab.Execute("quit")
I don't know if this will fix the error though.
Respuestas (3)
Surae
el 20 de Jul. de 2011
1 comentario
Chirag Gupta
el 20 de Jul. de 2011
Please accept your answer, so that it is easily available to others!
Chirag Gupta
el 19 de Jul. de 2011
Kaustubha's suggestion looks good to me. Is your routine f_ann finished when you try and exit?
0 comentarios
Ver también
Categorías
Más información sobre Data Export to MATLAB en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!