public static skRefund GetRefundObject(int ID) { DataFunctions DB = new DataFunctions(); skRefund RefundOBJ = DB.GetRefundDetails(ID); if (RefundOBJ != null) { return(RefundOBJ); } else { throw new Exception("No Refund Found"); } }
public static void OpenRefundTab(skRefund RefundOBJ) { ObjectMessenger om = new ObjectMessenger(); if (RefundOBJ != null) { om.Send("TRANOBJ", RefundOBJ); UI.Enviroment.LoadNewTab("SalesDetailsView"); } else { throw new Exception("No Sale with this ID can be found."); } }
public static skRefund GetRefundObject(int ID) { Stocky.Proxies.AppDataClient DataClient = new Proxies.AppDataClient(); try { DataClient.Open(); skRefund RefundOBJ = DataClient.GetRefundObject(ID).RefundObject; if (RefundOBJ != null) { return(RefundOBJ); } else { throw new Exception("No Refund Found"); } } finally { DataClient.Close(); } }