close
Blogtrottr
Yahoo!奇摩知識+ - 分類問答 - 電腦網路 - 發問中
Yahoo!奇摩知識+ - 分類問答 - 電腦網路 - 發問中 
Visual studio C#語法問題
Jan 15th 2015, 06:24

就是我用C#再寫一個點餐的系統,我在Form1想跳到Form2的餐點收據卡住了,原因是我不知道如何讓Form1的餐點總金額 及 付款後找零 顯示在Form2 還有如何讓我點選的餐點 漢堡x2 可樂x3 這樣顯示在Form2

{
int total2 = System.Convert.ToInt32(textBox1.Text);
int price = total2 - total;
if ((total2 - total) > 0)
{
label6.Text = "找您 " + price + "元";
}
else
{
label6.Text = "付款不足";
}
int g = price / 500;
int i = price % 500 / 100;
int n = price % 100 / 50;
int m = price % 50 / 10;
int v = price % 10 / 5;
int b = price % 5;
label1.Text = "500元" + g + "張\n" + " " + "100元" + i + "張\n" + " " + "50元" + n + "個\n" + " " + "10元" + m + "個\n"
+ " " + "5元" + v + "個\n" + " " + "1元" + b + "個\n" + " " ;
}
這是我的button

Recommended article: Chomsky: We Are All – Fill in the Blank.
This entry passed through the Full-Text RSS service - if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publishers.

You are receiving this email because you subscribed to this feed at blogtrottr.com.

If you no longer wish to receive these emails, you can unsubscribe from this feed, or manage all your subscriptions
arrow
arrow
    全站熱搜
    創作者介紹
    創作者 kkovdy25d40iq 的頭像
    kkovdy25d40iq

    線上遊戲排行榜2013/2014,進擊的巨人線上看,candy crush saga外掛,正妹寫真三圍

    kkovdy25d40iq 發表在 痞客邦 留言(0) 人氣()