28cd89ae9056e763d0431ce3f773c99c4aac6ca7.svn-base 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Windows.Forms;
  9. using CoreFS.CA06;
  10. using Infragistics.UltraChart.Shared.Styles;
  11. namespace Core.LZMes.Client.UIK.UIK05
  12. {
  13. public partial class UIK050051 : FrmBase
  14. {
  15. public UIK050051()
  16. {
  17. InitializeComponent();
  18. }
  19. string sTime_1 = null;
  20. string eTime_1 = null;
  21. string thick_1 = null;
  22. string flat_1 = null;
  23. string setthick_1 = null;
  24. string coilid_1 = null;
  25. public string thick
  26. {
  27. set
  28. {
  29. thick_1 = value;
  30. }
  31. }
  32. public string flat
  33. {
  34. set
  35. {
  36. flat_1 = value;
  37. }
  38. }
  39. public string sTime
  40. {
  41. set
  42. {
  43. sTime_1 = value;
  44. }
  45. }
  46. public string eTime
  47. {
  48. set
  49. {
  50. eTime_1 = value;
  51. }
  52. }
  53. public string coilid
  54. {
  55. set
  56. {
  57. coilid_1 = value;
  58. }
  59. }
  60. public string setthick
  61. {
  62. set
  63. {
  64. setthick_1 = value;
  65. }
  66. }
  67. private void UIK050051_Load(object sender, EventArgs e)
  68. {
  69. CoreClientParam ccp = new CoreClientParam();
  70. ccp.ServerName = "UIK.UIK05.UIK050010";
  71. ccp.MethodName = "DoQueryCoilThick";
  72. ccp.ServerParams = new object[] { coilid_1 };
  73. ccp.SourceDataTable = this.dataSet2.Tables[0];
  74. this.ExecuteQueryToDataTable(ccp, CoreInvokeType.Internal);
  75. string COILTHICK1 = this.dataSet2.Tables[0].Rows[0]["COILTHICK1"].ToString();
  76. string COILTHICK2 = this.dataSet2.Tables[0].Rows[0]["COILTHICK2"].ToString();
  77. thick_1 = COILTHICK1 + COILTHICK2;
  78. flat_1 = this.dataSet2.Tables[0].Rows[0]["COILFLAT"].ToString();
  79. //DataRowCollection drc2 = this.dataSet2.Tables[0].Rows;
  80. DataTable table = new DataTable();
  81. // string str = "1.1480;0.9980;0.9895;0.9852;0.9825;0.9870;0.9845;0.9800;0.9839;0.9822;0.9840;0.9832;0.9852;0.9823;0.9880;0.9839;0.9877;0.9854;0.9826;0.9875;0.9830;0.9869;0.9834;0.9843;0.9854;0.9858;0.9840;0.9833;0.9861;0.9859;0.9863;0.9838;0.9832;0.9851;0.9867;0.9827;0.9855;0.9846;0.9855;0.9867;0.9843;0.9853;0.9821;0.9884;0.9833;0.9848;0.9847;0.9844;0.9845;0.9829;0.9851;0.9834;0.9855;0.9841;0.9870;0.9841;0.9852;0.9854;0.9846;0.9834;0.9842;0.9875;0.9845;0.9866;0.9833;0.9840;0.9856;0.9849;0.9826;0.9845;0.9845;0.9863;0.9876;0.9816;0.9860;0.9856;0.9881;0.9854;0.9862;0.9817;0.9854;0.9872;0.9838;0.9824;0.9817;0.9861;0.9847;0.9834;0.9846;0.9857;0.9877;0.9840;0.9841;0.9847;0.9882;0.9844;0.9851;0.9841;0.9820;0.9859;0.9885;0.9842;0.9854;0.9830;0.9861;0.9864;0.9846;0.9845;0.9841;0.9861;0.9839;0.9867;0.9832;0.9844;0.9883;0.9859;0.9874;0.9833;0.9849;0.9840;0.9849;0.9854;0.9873;0.9851;0.9845;0.9858;0.9848;0.9867;0.9847;0.9862;0.9818;0.9853;0.9859;0.9864;0.9842;0.9847;0.9871;0.9870;0.9855;0.9850;0.9838;0.9844;0.9872;0.9852;0.9851;0.9841;0.9857;0.9869;0.9838;0.9849;0.9845;0.9867;0.9854;0.9853;0.9844;0.9833;0.9849;0.9868;0.9878;0.9834;0.9831;0.9833;0.9867;0.9847;0.9850;0.9830;0.9857;0.9850;0.9861;0.9835;0.9813;0.9868;0.9840;0.9851;0.9811;0.9834;0.9853;0.9838;0.9843;0.9829;0.9850;0.9853;0.9857;0.9829;0.9854;0.9852;0.9874;0.9849;0.9831;0.9843;0.9837;0.9878;0.9830;0.9833;0.9845;0.9862;0.9849;0.9841;0.9835;0.9859;0.9871;0.9831;0.9831;0.9837;0.9866;0.9858;0.9823;0.9850;0.9858;0.9834;0.9846;0.9841;0.9844;0.9843;0.9831;0.9843;0.9823;0.9839;0.9850;0.9852;0.9836;0.9842;0.9856;0.9849;0.9872;0.9804;0.9847;0.9829;0.9885;0.9864;0.9845;0.9860;1.0273;0.9638;0.9721;0.9959;0.9938";
  82. string[] arr0 = thick_1.Split('"');
  83. string[] arr01 = arr0[1].Split(';');
  84. string[] arr1 = (from s in arr01 where !string.IsNullOrEmpty(s) select s).ToArray();
  85. //int columnno = this.dataSet1.Tables[0].Columns.Count;
  86. int columnno = arr1.Length;
  87. string[] thkdate = new string[columnno];
  88. for (int i = 0; i < columnno; i++)
  89. {
  90. table.Columns.Add((i * 10).ToString(), typeof(double));
  91. thkdate[i] = arr1[i];
  92. }
  93. object[] Data1 = new object[]
  94. {
  95. thkdate
  96. };
  97. for (int i = 0; i < Data1.Length; i++)
  98. {
  99. DataRow row = table.NewRow();
  100. row.ItemArray = (object[])Data1[i];
  101. table.Rows.Add(row);
  102. }
  103. this.ultraChart1.Data.DataSource = table;
  104. this.ultraChart1.Data.DataBind();
  105. this.ultraChart1.ChartType = Infragistics.UltraChart.Shared.Styles.ChartType.LineChart;
  106. this.ultraChart1.Axis.Y.Labels.ItemFormatString = "<DATA_VALUE:0.##>";
  107. this.ultraChart1.Tooltips.FormatString = "<ITEM_LABEL>m处:<DATA_VALUE:0.####>";
  108. this.ultraChart1.Axis.Y.TickmarkStyle = AxisTickStyle.DataInterval;
  109. this.ultraChart1.Axis.X.Labels.HorizontalAlign = System.Drawing.StringAlignment.Near;
  110. this.ultraChart1.Axis.X.Labels.Orientation = Infragistics.UltraChart.Shared.Styles.TextOrientation.Horizontal;
  111. this.ultraChart1.Legend.Location = Infragistics.UltraChart.Shared.Styles.LegendLocation.Left;
  112. this.ultraChart1.Axis.Y.LineEndCapStyle = Infragistics.UltraChart.Shared.Styles.LineCapStyle.ArrowAnchor;
  113. this.ultraChart1.TitleTop.Text = "钢卷厚度";
  114. DataTable table1 = new DataTable();
  115. // string str = "1.1480;0.9980;0.9895;0.9852;0.9825;0.9870;0.9845;0.9800;0.9839;0.9822;0.9840;0.9832;0.9852;0.9823;0.9880;0.9839;0.9877;0.9854;0.9826;0.9875;0.9830;0.9869;0.9834;0.9843;0.9854;0.9858;0.9840;0.9833;0.9861;0.9859;0.9863;0.9838;0.9832;0.9851;0.9867;0.9827;0.9855;0.9846;0.9855;0.9867;0.9843;0.9853;0.9821;0.9884;0.9833;0.9848;0.9847;0.9844;0.9845;0.9829;0.9851;0.9834;0.9855;0.9841;0.9870;0.9841;0.9852;0.9854;0.9846;0.9834;0.9842;0.9875;0.9845;0.9866;0.9833;0.9840;0.9856;0.9849;0.9826;0.9845;0.9845;0.9863;0.9876;0.9816;0.9860;0.9856;0.9881;0.9854;0.9862;0.9817;0.9854;0.9872;0.9838;0.9824;0.9817;0.9861;0.9847;0.9834;0.9846;0.9857;0.9877;0.9840;0.9841;0.9847;0.9882;0.9844;0.9851;0.9841;0.9820;0.9859;0.9885;0.9842;0.9854;0.9830;0.9861;0.9864;0.9846;0.9845;0.9841;0.9861;0.9839;0.9867;0.9832;0.9844;0.9883;0.9859;0.9874;0.9833;0.9849;0.9840;0.9849;0.9854;0.9873;0.9851;0.9845;0.9858;0.9848;0.9867;0.9847;0.9862;0.9818;0.9853;0.9859;0.9864;0.9842;0.9847;0.9871;0.9870;0.9855;0.9850;0.9838;0.9844;0.9872;0.9852;0.9851;0.9841;0.9857;0.9869;0.9838;0.9849;0.9845;0.9867;0.9854;0.9853;0.9844;0.9833;0.9849;0.9868;0.9878;0.9834;0.9831;0.9833;0.9867;0.9847;0.9850;0.9830;0.9857;0.9850;0.9861;0.9835;0.9813;0.9868;0.9840;0.9851;0.9811;0.9834;0.9853;0.9838;0.9843;0.9829;0.9850;0.9853;0.9857;0.9829;0.9854;0.9852;0.9874;0.9849;0.9831;0.9843;0.9837;0.9878;0.9830;0.9833;0.9845;0.9862;0.9849;0.9841;0.9835;0.9859;0.9871;0.9831;0.9831;0.9837;0.9866;0.9858;0.9823;0.9850;0.9858;0.9834;0.9846;0.9841;0.9844;0.9843;0.9831;0.9843;0.9823;0.9839;0.9850;0.9852;0.9836;0.9842;0.9856;0.9849;0.9872;0.9804;0.9847;0.9829;0.9885;0.9864;0.9845;0.9860;1.0273;0.9638;0.9721;0.9959;0.9938";
  116. string[] ar0 = flat_1.Split('"');
  117. string[] ar01 = ar0[1].Split(';');
  118. string[] ar1 = (from s in ar01 where !string.IsNullOrEmpty(s) select s).ToArray();
  119. //int columnno = this.dataSet1.Tables[0].Columns.Count;
  120. int columnno1 = ar1.Length;
  121. string[] thkdate1 = new string[columnno1];
  122. for (int i = 0; i < columnno1; i++)
  123. {
  124. table1.Columns.Add((i * 10).ToString(), typeof(double));
  125. thkdate1[i] = ar1[i];
  126. }
  127. object[] Data2 = new object[]
  128. {
  129. //thkdate,
  130. thkdate1
  131. };
  132. for (int i = 0; i < Data2.Length; i++)
  133. {
  134. DataRow row = table1.NewRow();
  135. row.ItemArray = (object[])Data2[i];
  136. table1.Rows.Add(row);
  137. }
  138. this.ultraChart2.Data.DataSource = table1;
  139. this.ultraChart2.Data.DataBind();
  140. this.ultraChart2.ChartType = Infragistics.UltraChart.Shared.Styles.ChartType.LineChart;
  141. this.ultraChart2.Axis.Y.Labels.ItemFormatString = "<DATA_VALUE:0.##>";
  142. this.ultraChart2.Tooltips.FormatString = "<ITEM_LABEL>m处:<DATA_VALUE:0.####>";
  143. this.ultraChart2.Axis.Y.TickmarkStyle = AxisTickStyle.DataInterval;
  144. this.ultraChart2.Axis.X.Labels.HorizontalAlign = System.Drawing.StringAlignment.Near;
  145. this.ultraChart2.Axis.X.Labels.Orientation = Infragistics.UltraChart.Shared.Styles.TextOrientation.Horizontal;
  146. this.ultraChart2.Legend.Location = Infragistics.UltraChart.Shared.Styles.LegendLocation.Left;
  147. this.ultraChart2.Axis.Y.LineEndCapStyle = Infragistics.UltraChart.Shared.Styles.LineCapStyle.ArrowAnchor;
  148. this.ultraChart2.TitleTop.Text = "板形";
  149. }
  150. }
  151. }