GetSaveFlag gives exception for result

Hi,

we have situation where we on GetSaveFlag instead of True or False get this exception: (Exception from HRESULT: 0x80010100 (RPC_E_SYS_CALL_FAILED)) What could be issue here, why we are getting this and how to solve it? We are using this method: 2012 SOLIDWORKS API Help - GetSaveFlag Method (IModelDoc2)

SolidworksApi macros