Exemple #1
0
        public int Create(Country mCountry)
        {
            try
            {
                //DB Persistent Login Here
                String mQuery = "Insert into country(name_eng,name_arb,code,currencyid)values('" + mCountry.Name_Eng + "','" + mCountry.Name_Arb + "','" + mCountry.Code + "','" + mCountry.Currencyid + "')";
                // Define a query
                int retv = CR.Postfunctions(mQuery);

                return(retv);
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message);
            }
            finally
            {
                //
            }
        }
Exemple #2
0
        public int Create(Currency mCurrency)
        {
            try
            {
                //DB Persistent Login Here
                String mQuery = "Insert into currency(name,code,decimal)values('" + mCurrency.Name + "','" + mCurrency.Code + "','" + mCurrency.Decimals + "')";
                // Define a query
                int retv = CR.Postfunctions(mQuery);

                return(retv);
            }
            catch (Exception ex)
            {
                throw new Exception(ex.Message);
            }
            finally
            {
                //
            }
        }