コード例 #1
0
        private static void ConectarComSAP()
        {
            SAPConnection.SBOApplicationHandler applicationHandler = null;
            applicationHandler += Dialogs.RecebeSBOApplication;
            applicationHandler += Menu.RecebeSBOApplication;
            applicationHandler += applicationParam => _sBOApplication = applicationParam;

            SAPConnection.CompanyHandler companyHandler = null;
            companyHandler += companyParam => _company = companyParam;
            companyHandler += Database.RecebeCompany;
            try
            {
                SAPConnection.Connect(applicationHandler, companyHandler);
            }
            catch (Exception e)
            {
                System.Windows.Forms.MessageBox.Show(e.Message);
                System.Windows.Forms.Application.Exit();
            }
        }