Esempio n. 1
0
        // Method that takes user to "billboard" form when button is clicked.
        private void rETURNToolStripMenuItem_Click(object sender, EventArgs e)
        {
            Billboard billboard = new Billboard();

            billboard.Show();
            this.Close();
        }
Esempio n. 2
0
        // Method that sends data from "prices page" to "billboard page" when export button is clicked.
        private void button_export_Click(object sender, EventArgs e)
        {
            Billboard billboard = new Billboard();

            billboard.ad_ToNewForm = txtbox_ad.Text;

            price95  = txtbox_95.Text;
            price98  = txtbox_98.Text;
            priceDsl = txtbox_dsl.Text;

            Gas95 = label_95_price.Text;
            billboard.gas95(Gas95.ToString());
            Gas98 = label_98_price.Text;
            billboard.gas98(Gas98.ToString());
            Dsl = label_dsl_price.Text;
            billboard.dsl(Dsl.ToString());

            Advertise1 = txtbox_ad.Text;
            billboard.advertise1(Advertise1.ToString());

            using (StreamWriter outputFile = new StreamWriter(filePath))
            {
                outputFile.WriteLine("Price95 = " + price95);
                outputFile.WriteLine("Price98 = " + price98);
                outputFile.WriteLine("PriceDsl = " + priceDsl);
            }

            billboard.Show();
            this.Close();
        }