Ejemplo n.º 1
0
 public void LoadFromObj(COCostSummary oOrg)
 {
     miID          = oOrg.ID;
     miProjectID   = oOrg.ProjectID;
     msNumber      = oOrg.Number;
     msManager     = oOrg.Manager;
     msTitle       = oOrg.Title;
     mbShowDollars = oOrg.ShowDollars;
     msComments    = oOrg.Comments;
 }
Ejemplo n.º 2
0
 public void Copy(COCostSummary oNew)
 {
     oNew.ID          = miID;
     oNew.ProjectID   = miProjectID;
     oNew.Number      = msNumber;
     oNew.Manager     = msManager;
     oNew.Title       = msTitle;
     oNew.ShowDollars = mbShowDollars;
     oNew.Comments    = msComments;
 }
Ejemplo n.º 3
0
        private void LoadVals(string strXml)
        {
            XmlSerializer s;
            StringReader  sr;

            s  = new XmlSerializer(typeof(COCostSummary));
            sr = new System.IO.StringReader(strXml);

            oVar = new COCostSummary();
            oVar = (COCostSummary)s.Deserialize(sr);

            sr.Close();
            sr = null;
            s  = null;
        }
Ejemplo n.º 4
0
        public void LoadVals(string strXml)
        {
            XmlSerializer s;
            StringReader  sr;
            COCostSummary o;

            s  = new XmlSerializer(typeof(COCostSummary));
            sr = new System.IO.StringReader(strXml);

            o = new COCostSummary();
            o = (COCostSummary)s.Deserialize(sr);

            base.LoadFromObj(o);

            o = null;
            sr.Close();
            sr = null;
            s  = null;
        }
Ejemplo n.º 5
0
        public string GetByProject(int lID)
        {
            SqlDataReader dr;

            RSLib.CDbConnection cnn;
            SqlCommand          cmd;
            SqlParameter        prm;
            string tmpStr = "";

            cnn             = new RSLib.CDbConnection();
            cmd             = new SqlCommand("spCostSummary_ByProjectID", cnn.GetConnection());
            cmd.CommandType = CommandType.StoredProcedure;


            prm       = cmd.Parameters.Add("@ProjectID", SqlDbType.Int);
            prm.Value = lID;

            dr = cmd.ExecuteReader(CommandBehavior.CloseConnection);


            while (dr.Read())
            {
                oVar = new COCostSummary();

                oVar.ID          = Convert.ToInt32(dr["ID"]);
                oVar.ProjectID   = Convert.ToInt32(dr["ProjectID"]);
                oVar.Number      = dr["Number"].ToString();
                oVar.Manager     = dr["Manager"].ToString();
                oVar.Title       = dr["Title"].ToString();
                oVar.ShowDollars = Convert.ToBoolean(dr["ShowDollars"]);
                oVar.Comments    = dr["Comments"].ToString();
                tmpStr           = GetDataString();
            }

            dr  = null;
            prm = null;
            cmd = null;
            cnn.CloseConnection();
            cnn = null;

            return(tmpStr);
        }
Ejemplo n.º 6
0
        public string GetDataString()
        {
            string        tmpStr;
            COCostSummary o;
            XmlSerializer s;
            StringWriter  sw;

            o  = new COCostSummary();
            s  = new XmlSerializer(typeof(COCostSummary));
            sw = new StringWriter();

            base.Copy(o);
            s.Serialize(sw, o);

            tmpStr = sw.ToString();

            o  = null;
            s  = null;
            sw = null;

            return(tmpStr);
        }