销售管理/Sales_statistics.cs
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
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;
using System.Data.SqlClient;
using System.Windows.Forms.DataVisualization.Charting;
namespace Car.销售管理
{
public partial class Sales_statistics : Form
{
// SqlConnection conn;
//SqlDataAdapter dap;
// DataSet ds;
//string con, sql;
public Sales_statistics()
{
InitializeComponent();
}
protected override CreateParams CreateParams //防止界面闪烁
{
get
{
CreateParams paras = base.CreateParams;
paras.ExStyle |= 0x02000000;
return paras;
}
}
private void Sales_statistics_Load(object sender, EventArgs e)
{
this.BackColor = Color.FromArgb(81, 81, 81);
this.skinEngine1.SkinFile = "SteelBlue.ssk";
ct.ChartAreas[0].AxisX.Interval = 1;//X轴数据显示间隔
ct.ChartAreas[0].AxisY.Maximum = 30;//设定y轴的最大值
ct.ChartAreas[0].AxisX.Minimum =0 ;//设定x轴的最小值
//x轴数据
List<string> txDate = new List<string>() { "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11" ,"12"};
//统计销售量
string sql2 = string.Format("select count(*) from car_commodity where car_zhuangtai='已出售'");
DataTable CountTable = DBHelper.GetDataTable(sql2);
Series s = ct.Series.Add(Convert.ToString(CountTable.Rows[0][0]));
int[] y = new int[12];
for (int i = 0; i < CountTable.Rows.Count; i++)
{
if (CountTable.Rows != null)
{
y[i] = int.Parse(CountTable.Rows[i][0].ToString());
}
}
//统计总量
string sql3 = string.Format("select count(*) from v_caigou_commodity_type where car_zhuangtai='未出售'");
后面还有 18 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。
