项目计划
   完成这个项目需要的时间:5-7天
项目开发
  需求分析:
    作为一名排球赛事管理者,我希望能够根据比赛查询每场比赛的结果,以便于确定每支球队的比赛名次。
  设计文档
    由排球比赛用户故事的需求分析可知,此程序是用来统计各个队伍的比分和积分情况,并加以排名。
  计划复审
 目前在进行中

public partial class Form1 : Form
{
 Action action = new Action();

public void INSERT()
{
Model q = new Model();
q.IDA = textBox1.Text.Trim().ToString();
q.IDB = textBox2.Text.Trim().ToString();
q.ONE = txtCount1.Text.Trim().Substring(4, 4);
q.TWO = txtCount2.Text.Trim().Substring(4, 4);
q.THREE = txtCount3.Text.Trim().Substring(4, 4);
if (txtCount4.Text =="")
{
q.FOUR = null;
}
else
{
q.FOUR = txtCount4.Text.Trim().Substring(4, 4);
}
if (txtCount5.Text =="")
{
q.FIVE= null;
}
else
{
q.FIVE = txtCount5.Text.Trim().Substring(4, 4);
}

q.SUM = txtH1.Text.ToString() + ":" + txtL1.Text.ToString();
q.Detail = sb.ToString();
action.InsertPK(M);
}
public Form1()
{
InitializeComponent();

}

int i = 1;
StringBuilder sb = new StringBuilder();
private void btnH_Click(object sender, EventArgs e)
{
int H = Convert.ToInt32(txtH.Text);
int L = Convert.ToInt32(txtL.Text);
int H1 = Convert.ToInt32(txtH1.Text);
int L1 = Convert.ToInt32(txtL1.Text);
txtH.Text = (H+1).ToString();
sb.AppendFormat("第{0}个球 {1}:{2}\r\n",H+1,H+1,L);
if (H >= 24 && (H - L) > 0)
{
txtH1.Text = (Convert.ToInt32(txtH1.Text) + 1).ToString();
if((H1+L1)==0){
txtCount1.Text += "第" + (i++) + "局:" + txtH.Text + ":" + txtL.Text;
}
if (txtH1.Text == "3")
{
MessageBox.Show(textBox1.Text+"胜利");
INSERT();
txtH.Text = "0";
txtH1.Text = "0";
txtL.Text = "0";
txtL1.Text = "0";
txtCount1.Clear();
txtCount2.Clear();
txtCount3.Clear();
txtCount4.Clear();
txtCount5.Clear();
}
}
if (H1 + L1 > 3)
{
if (H >= 14 && (H - L) > 1)
{
txtH1.Text = (Convert.ToInt32(txtH1.Text) + 1).ToString();

if ((H1 + L1) == 4)
{
txtCount5.Text += "第" + (i++) + "局:" + txtH.Text + ":" + txtL.Text + "\r\n";
}
txtH.Text = "0";
txtL.Text = "0";

if (txtH1.Text == "3")
{
MessageBox.Show(textBox1.Text + "胜利");
INSERT();
txtH.Text = "0";
txtH1.Text = "0";
txtL.Text = "0";
txtL1.Text = "0";
txtCount1.Clear();
txtCount2.Clear();
txtCount3.Clear();
txtCount4.Clear();
txtCount5.Clear();
i = 1;
}
}
}
}
private void btnL_Click(object sender, EventArgs e)
{

int H = Convert.ToInt32(txtH.Text);
int L = Convert.ToInt32(txtL.Text);
int H1 = Convert.ToInt32(txtH1.Text);
int L1 = Convert.ToInt32(txtL1.Text);
txtL.Text = (L+1).ToString();
sb.AppendFormat("第{0}个球 {1}:{2}\r\n", L + 1, H, L+1);
if (L>= 24&&(L-H )>0)
{
txtL1.Text = (Convert.ToInt32(txtL1.Text) + 1).ToString();
if((H1+L1)==0){
txtCount1.Text += "第" + (i++) + "局:" + txtH.Text + ":" + txtL.Text;
} if ((H1 + L1) == 1)
{
txtCount2.Text += "第" + (i++) + "局:" + txtH.Text + ":" + txtL.Text;
}
if ((H1 + L1) == 2)
{
txtCount3.Text += "第" + (i++) + "局:" + txtH.Text + ":" + txtL.Text;
}
if ((H1 + L1) == 3)
{
txtCount4.Text += "第" + (i++) + "局:" + txtH.Text + ":" + txtL.Text;
}
if ((H1 + L1) == 4)
{
txtCount5.Text += "第" + (i++) + "局:" + txtH.Text + ":" + txtL.Text;
}
txtH.Text = "0";
txtL.Text = "0";

if (txtL1.Text=="3")
{
MessageBox.Show(textBox2.Text + "胜利");
INSERT();
txtH.Text = "0";
txtH1.Text = "0";
txtL.Text = "0";
txtL1.Text = "0";
txtCount1.Clear();
txtCount2.Clear();
txtCount3.Clear();
txtCount4.Clear();
txtCount5.Clear();
}

第十八周个人作业--The Final的更多相关文章

  1. 达拉草201771010105《面向对象程序设计(java)》第十八周学习总结

    达拉草201771010105<面向对象程序设计(java)>第十八周学习总结 实验十八  总复习 实验时间 2018-12-30 1.实验目的与要求 (1) 综合掌握java基本程序结构 ...

  2. 20155213 第十二周课堂作业MySort

    20155213 第十二周课堂作业MySort 作业要求 模拟实现Linux下Sort -t : -k 2的功能 参考 Sort的实现 提交码云链接和代码运行截图 初始代码 1 import java ...

  3. 第十八周java实验作业

    实验十八  总复习 实验时间 2018-12-30 1.实验目的与要求 (1) 综合掌握java基本程序结构: (2) 综合掌握java面向对象程序设计特点: (3) 综合掌握java GUI 程序设 ...

  4. 201771010126 王燕《面向对象程序设计(java)》第十八周学习总结

    实验十八  总复习 实验时间 2018-12-30 1.实验目的与要求 (1) 综合掌握java基本程序结构: (2) 综合掌握java面向对象程序设计特点: (3) 综合掌握java GUI 程序设 ...

  5. 马昕璐 201771010118《面向对象程序设计(java)》第十八周学习总结

    实验十八  总复习 实验时间 2018-12-30 1.实验目的与要求 (1) 综合掌握java基本程序结构: (2) 综合掌握java面向对象程序设计特点: (3) 综合掌握java GUI 程序设 ...

  6. 王颖奇 201771010129《面向对象程序设计Java》第十八周实验总结

    实验十八  总复习 实验时间 2018-12-30 1.实验目的与要求 (1) 综合掌握java基本程序结构: (2) 综合掌握java面向对象程序设计特点: (3) 综合掌握java GUI 程序设 ...

  7. 第十四,十五周PTA作业

    1.第十四周part1 7-3 #include<stdio.h> int main() { int n; scanf("%d",&n); int a[n]; ...

  8. 刘志梅 201771010115 《面向对象程序设计(java)》 第十八周学习总结

    实验十八 总复习 实验时间 2018-12-30 1.实验理论知识 (1)第一个关键词:public称为访问修饰符,用于控制程序的其他部分对代码的访问级别. 第二个关键词:class表明java程序中 ...

  9. 王艳 201771010127《面向对象程序设计(java)》第十八周学习总结

    实验十八  总复习 实验时间 2018-12-30 1.实验目的与要求 (1) 综合掌握java基本程序结构: (2) 综合掌握java面向对象程序设计特点: (3) 综合掌握java GUI 程序设 ...

随机推荐

  1. iOS开发项目之MVC与MVVM

    MVC MVC,Model-View-Controller,我们从这个古老而经典的设计模式入手.采用 MVC 这个架构的最大的优点在于其概念简单,易于理解,几乎任何一个程序员都会有所了解,几乎每一所计 ...

  2. maven Error resolving version for plugin 'org.apache.maven.plugins:maven-eclipse-plugin' from the repositories 解决

    报错:Error resolving version for plugin 'org.apache.maven.plugins:maven-eclipse-plugin' from the repos ...

  3. Jackson的使用

    Jackson框架是基于Java平台的一套数据处理工具,被称为"最好的JavaJson解析器". Jackson框架包含了3个核心库:streaming,databind,anno ...

  4. Android Studio 高级配置

    http://liukun.engineer/2016/04/10/Android-Studio-advanced-configuration/

  5. [POJ2761] Feed the dogs (Treap)

    题目链接:http://poj.org/problem?id=2761 题目大意:给你n个数,m次查询,m次查询分别是a,b,k,查询下表从a到b的第k小元素是哪个.这m个区间不会互相包含. Trea ...

  6. Codeforces Round #232 (Div. 2) D. On Sum of Fractions

    D. On Sum of Fractions Let's assume that v(n) is the largest prime number, that does not exceed n; u ...

  7. SQL Server获取月度列表

    -- 获取月度列表 if exists(select 1 from sysobjects where name = 'proc_GetDateMonthList' and type = 'p') dr ...

  8. unity自定义菜单面板开发

    using UnityEditor;using UnityEngine;using CreateTerrainDLL; public class CreateTerrainMenu : EditorW ...

  9. C#编写WIN32系统托盘程序

    基本功能概述: 程序运行后驻留系统托盘,左键呼出,右键退出.后续可加右键菜单. 注册系统案件WIN+F10,呼出程序. 重写系统消息,最小化和关闭按钮隐藏程序 using System; using ...

  10. js处理url参数

    var UrlArgent = { Parsed: false, //是否已解析 Cache: {}, //缓存值 ParseArg: function () { // 解析地址栏的参数值 UrlAr ...