12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Drawing;
- using System.Data;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- namespace LYFZ.ComponentLibrary
- {
- public partial class DataGridViewStatisticsCount : UserControl
- {
- public DataGridViewStatisticsCount()
- {
- InitializeComponent();
- }
- private int _LocationX = 1;
- /// <summary>
- /// 显示的X坐标
- /// </summary>
- public int LocationX
- {
- get { return _LocationX; }
- set
- {
- _LocationX = value;
- this.labelEx1.Location = new Point(LocationX, this.labelEx1.Location.Y);
- }
- }
- private string _StrUnit = "单";
- /// <summary>
- /// 单位
- /// </summary>
- [Bindable(false)]
- public string StrUnit
- {
- get { return _StrUnit; }
- set { _StrUnit = value; }
- }
- private int _CurrenQuantity = 0;
- /// <summary>
- /// 当前数量
- /// </summary>
- public int CurrenQuantity
- {
- get { return _CurrenQuantity; }
- set { _CurrenQuantity = value; }
- }
- private int _TotalQuantity = 0;
- /// <summary>
- /// 总数量
- /// </summary>
- public int TotalQuantity
- {
- get { return _TotalQuantity; }
- set
- {
- _TotalQuantity = value;
- this.labelEx1.Text = "当前显示 " + this.CurrenQuantity + " " + this.StrUnit + " / 共 " + this.TotalQuantity + " " + this.StrUnit + "";
- }
- }
- }
- }
|