View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Ron de Bruin Ron de Bruin is offline
external usenet poster
 
Posts: 11,123
Default Trouble with exit

Try this

#If Mac Then
MsgBox "Sorry this Application runs in Windows only."
ThisWorkbook.Close False
Exit Sub
End If



--
Regards Ron de Bruin
http://www.rondebruin.nl


"jose luis" wrote in message ...

Thank you Ron,


The application recognizes the Mac and shows the MsgBox, but after that
I need to quit the application to prevent the user to continue working
with it. I set a Boolean var as flag to detect when the program went
into the #If MAC but it seems not to be working. Is there a way to
force the app to Close after the MsgBox?

Thanks again for your help.

Regards

jose luis


--
jose luis
------------------------------------------------------------------------
jose luis's Profile: http://www.excelforum.com/member.php...o&userid=13312
View this thread: http://www.excelforum.com/showthread...hreadid=261729