Tugas 1 PBKK_Membuat Aplikasi Toko Buah menggunakan NET Framework_5025211167

Nama : Muhammad Rafi Sutrisno

NRP : 5025211167

Kelas : PBKK - B

Tahun Ajaran : 2023


Pada tugas kali ini saya membuat Aplikasi Toko Buah Sederhana menggunakan NET Framework. Didalam aplikasi ini pengguna bisa memilih jumlah buah yang ingin dibeli dan akan ditunjukkan total harga yang harus dibayar.


Masukkan jumlah buah untuk masing masing buah yang ingin dibeli. jika sudah klik simpan maka total harga akan muncul. jika sudah selesai klik selesai dan aplikasi akan kembali ke awal.





Code:

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace NetFrameWork_Apps
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void label1_Click(object sender, EventArgs e)
        {

        }

        private void label6_Click(object sender, EventArgs e)
        {

        }

        private void label8_Click(object sender, EventArgs e)
        {

        }

        private void button_Clicks(object sender, EventArgs e){

            int n1 = int.Parse(textBox2.Text);
            int n2 = int.Parse(textBox3.Text);
            int n3 = int.Parse(textBox4.Text);

            textBox1.Text = "";
            textBox2.Text = "";
            textBox3.Text = "";
            textBox4.Text = "";

            int total = (n1 * 1000) + (n2 * 2000) + (n3 * 3000);

            textBox5.Text = total.ToString();
        }

        private void but2(object sender, EventArgs e)
        {
            textBox5.Text = "";
        }

        private void textBox3_TextChanged(object sender, EventArgs e)
        {

        }

        private void label11_Click(object sender, EventArgs e)
        {

        }

        private void button3_Click(object sender, EventArgs e)
        {

        }
    }
}



Komentar

Postingan populer dari blog ini

Pweb-Tugas13-PrintPDF

Tugas 5 - PBKK - 5025211167