Hi Mohammad,
May you provide the code for the ClsSBOAddOn.ExecuteSQL method?
Besides this, why not using an interface (make use of SAPbobsCOM.IRecordset instead of SAPbobsCOM.Recordset and remove the ref keywords) to transmit the Recordset object: by doing this, you would remove the need of the ref keyword...
Regards,
Eric