| | |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Linq; |
| | | using System.Text; |
| | | using System.Windows.Forms; |
| | | |
| | | namespace Yw.WinFrmUI.Phart |
| | | namespace Yw.WinFrmUI.Phart |
| | | { |
| | | /// <summary> |
| | | /// 剪切板文本辅助类 |
| | |
| | | var text = Clipboard.GetText(); |
| | | if (string.IsNullOrEmpty(text)) |
| | | return null; |
| | | if(neglectList != null && neglectList.Count>0) |
| | | if (neglectList != null && neglectList.Count > 0) |
| | | { |
| | | neglectList.ForEach(x => |
| | | { |
| | | text = text.Replace(x, ""); |
| | | }); |
| | | } |
| | | |
| | | |
| | | |
| | | var rows = text.Split(new string[] { "\r\n" }, StringSplitOptions.RemoveEmptyEntries).ToList(); |
| | | if (rows.Count < 1) |
| | | return null; |
| | | |
| | | |
| | | |
| | | var list = new List<List<double?>>(); |
| | | foreach (var row in rows) |
| | |
| | | r = null; |
| | | } |
| | | else |
| | | { |
| | | { |
| | | double d; |
| | | if (double.TryParse(x, out d)) |
| | | { |
| | |
| | | } |
| | | return colsList; |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } |