Ejemplo n.º 1
0
        private void checkNewJob()
        {
            if ((txtEmployer.Text != Employer || txtJob.Text != Job) && txtJob.Text != "")
            {
                clsDB     objDB     = new clsDB(strDB);
                clsFormat objFormat = new clsFormat();

                string strInsert = "Insert Into Job(Title, Description, Employer, Address,City, Zip,PlacementDate,Consumer_ID)";
                string strValues = " Values('" + txtJob.Text + "','" + objFormat.removeApostrophe(txtDescription.Text) + "','" + objFormat.removeApostrophe(txtEmployer.Text) + "','" + txtAddress.Text + "'";
                strValues = strValues + ",'" + txtCity.Text + "','" + objFormat.formatZip(txtZip.Text) + "'," + objFormat.formatDate(txtPlacement.Text) + "," + ID + ")";

                objDB.assignJob(strInsert + strValues);

                // logic to email Kristen.
                clsEmail objEmail = new clsEmail();
                objEmail.MailInfo("*****@*****.**", txtConsumer.Text);
            }
        }