|
|
@@ -78,7 +78,7 @@ namespace OTSIncAReportGrids
|
|
|
frmReportConditionChoose m_condition;
|
|
|
FieldData fieldData;
|
|
|
DataTable particlesAll;
|
|
|
- DataTable particles;
|
|
|
+ DataTable particlesFilter;
|
|
|
public ParticleData Particledata;
|
|
|
public UserSTDDbAccess userSTDDb;
|
|
|
public FieldImage fldImgAccess;
|
|
|
@@ -377,8 +377,8 @@ namespace OTSIncAReportGrids
|
|
|
DataTable XRayData = Particledata.GetXRayData();
|
|
|
for (int i = 0; i < particlesAll.Rows.Count; i++)
|
|
|
{
|
|
|
- string subt = particlesAll.Rows[i]["SubParticles"].ToString();
|
|
|
- if (subt =="")
|
|
|
+ string subParticleString = particlesAll.Rows[i]["SubParticles"].ToString();
|
|
|
+ if (subParticleString =="")
|
|
|
{
|
|
|
particlesAll.Rows[i]["XRayDataCount"] = 0;
|
|
|
string str = " XrayIndex= " + particlesAll.Rows[i]["particleId"].ToString() + " and fieldid = " + particlesAll.Rows[i]["fieldid"].ToString();
|
|
|
@@ -406,9 +406,8 @@ namespace OTSIncAReportGrids
|
|
|
|
|
|
particlesAll.Rows[i]["XRayDataCount"] = 0;
|
|
|
DataRow dgvr = particlesAll.Rows[i];
|
|
|
- uint[] Search_xray = new uint[2000];
|
|
|
uint[] Analysis_xray = new uint[2000];
|
|
|
- Particledata.GetXrayByParticleTagIDAndFieldID_ForMergeParticle(Convert.ToInt32(dgvr["particleId"]), Convert.ToInt32(dgvr["fieldid"]), out Search_xray, out Analysis_xray);
|
|
|
+ Particledata.GetXrayByParticleTagIDAndFieldID_ForMergeParticle(Convert.ToInt32(dgvr["particleId"]), Convert.ToInt32(dgvr["fieldid"]), out Analysis_xray);
|
|
|
uint xraycount = 0;
|
|
|
for (int j = 0; j < 2000; j++)
|
|
|
{
|
|
|
@@ -468,14 +467,14 @@ namespace OTSIncAReportGrids
|
|
|
return;
|
|
|
}
|
|
|
RecordCount = particlesAll.Rows.Count;
|
|
|
- particles = particlesAll.Clone();
|
|
|
+ particlesFilter = particlesAll.Clone();
|
|
|
for (int fi = (PageIndex - 1) * pageSize; fi < PageIndex * pageSize; fi++)
|
|
|
{
|
|
|
if (fi > RecordCount - 1)
|
|
|
{
|
|
|
break;
|
|
|
}
|
|
|
- particles.ImportRow(particlesAll.Rows[fi]);
|
|
|
+ particlesFilter.ImportRow(particlesAll.Rows[fi]);
|
|
|
}
|
|
|
|
|
|
List<string> ElementTypeSort = new List<string>(str_ElementsColName.Split(',').ToList());//去重
|
|
|
@@ -492,10 +491,10 @@ namespace OTSIncAReportGrids
|
|
|
int id = dgV_ParticlesDevidePage.Columns.Count;
|
|
|
dgV_ParticlesDevidePage.Columns[id - 1].Tag = "NumericType";
|
|
|
}
|
|
|
- double jd = 95f / (double)particles.Rows.Count;
|
|
|
+ double jd = 95f / (double)particlesFilter.Rows.Count;
|
|
|
string filePath = result.FilePath + "\\FIELD_FILES\\";
|
|
|
|
|
|
- for (int i = 0; i < particles.Rows.Count; i++)
|
|
|
+ for (int i = 0; i < particlesFilter.Rows.Count; i++)
|
|
|
{
|
|
|
if (i % 10 == 0)
|
|
|
m_frm_userprogress.SetProgressValueAndText((int)(jd * i), "loading..");
|
|
|
@@ -511,62 +510,62 @@ namespace OTSIncAReportGrids
|
|
|
{
|
|
|
if (enl.Current.Key == "ParticleImage")
|
|
|
{
|
|
|
- string subt = particles.Rows[i]["SubParticles"].ToString();
|
|
|
+ string subParticleString = particlesFilter.Rows[i]["SubParticles"].ToString();
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Height = 150;
|
|
|
|
|
|
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Style.BackColor = Color.Azure;
|
|
|
|
|
|
Bitmap bmap = null;
|
|
|
- if (subt != null && subt != "" && subt != "IsSubParticle")
|
|
|
+ if (subParticleString != null && subParticleString != "" && subParticleString != "IsSubParticle")
|
|
|
{
|
|
|
double pix = result.GetPixelSize();
|
|
|
int width = result.GetImageWidth();
|
|
|
int height = result.GetImageHeight();
|
|
|
- string vs = "," + subt.Replace(':', '-') + ",";
|
|
|
+ string vs = "," + subParticleString.Replace(':', '-') + ",";
|
|
|
DataTable dataTable = Particledata.GetParticleAllForBig(vs);//组成拼接颗粒的子颗粒
|
|
|
- bmap = fldImgAccess.GetBitmapForMergedParticle(subt, pix, height, width, dataTable);
|
|
|
+ bmap = fldImgAccess.GetBitmapForMergedParticle(subParticleString, pix, height, width, dataTable);
|
|
|
if (bmap != null)
|
|
|
{
|
|
|
- string[] str = subt.Split(',');
|
|
|
+ string[] str = subParticleString.Split(',');
|
|
|
bmap.Tag = new List<string>() { str[0].Split(':')[0], str[0].Split(':')[1] };
|
|
|
}
|
|
|
}
|
|
|
- else if (subt != "IsSubParticle")
|
|
|
+ else if (subParticleString != "IsSubParticle")
|
|
|
{
|
|
|
- if (!fieldpics.Keys.Contains(particles.Rows[i]["fieldid"].ToString()))
|
|
|
+ if (!fieldpics.Keys.Contains(particlesFilter.Rows[i]["fieldid"].ToString()))
|
|
|
{
|
|
|
- string imagePath = "Field" + particles.Rows[i]["fieldid"].ToString() + ".bmp";
|
|
|
- fieldpics.Add(particles.Rows[i]["fieldid"].ToString(), fldImgAccess.ReadImageFile(imagePath));
|
|
|
+ string imagePath = "Field" + particlesFilter.Rows[i]["fieldid"].ToString() + ".bmp";
|
|
|
+ fieldpics.Add(particlesFilter.Rows[i]["fieldid"].ToString(), fldImgAccess.ReadImageFile(imagePath));
|
|
|
}
|
|
|
- Rectangle rectangle = new Rectangle() { X = Convert.ToInt32(particles.Rows[i]["RectLeft"]), Y = Convert.ToInt32(particles.Rows[i]["RectTop"]), Width = Convert.ToInt32(particles.Rows[i]["RectWidth"]), Height = Convert.ToInt32(particles.Rows[i]["RectHeight"]) };
|
|
|
- bmap = fldImgAccess.CapturePic(fieldpics[particles.Rows[i]["fieldid"].ToString()], rectangle);
|
|
|
- bmap.Tag = new List<string>() { particles.Rows[i]["FieldId"].ToString(), particles.Rows[i]["ParticleId"].ToString()};
|
|
|
+ Rectangle rectangle = new Rectangle() { X = Convert.ToInt32(particlesFilter.Rows[i]["RectLeft"]), Y = Convert.ToInt32(particlesFilter.Rows[i]["RectTop"]), Width = Convert.ToInt32(particlesFilter.Rows[i]["RectWidth"]), Height = Convert.ToInt32(particlesFilter.Rows[i]["RectHeight"]) };
|
|
|
+ bmap = fldImgAccess.CapturePic(fieldpics[particlesFilter.Rows[i]["fieldid"].ToString()], rectangle);
|
|
|
+ bmap.Tag = new List<string>() { particlesFilter.Rows[i]["FieldId"].ToString(), particlesFilter.Rows[i]["ParticleId"].ToString()};
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Height = bmap.Height + 20;
|
|
|
}
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = bmap;
|
|
|
}
|
|
|
if (enl.Current.Key == "DiameterRatio")
|
|
|
{
|
|
|
- double d = Convert.ToDouble(particles.Rows[i]["DMAX"]) / Convert.ToDouble(particles.Rows[i]["DMIN"]);
|
|
|
+ double d = Convert.ToDouble(particlesFilter.Rows[i]["DMAX"]) / Convert.ToDouble(particlesFilter.Rows[i]["DMIN"]);
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = Math.Round(d, 2);
|
|
|
}
|
|
|
if (enl.Current.Key == "ASPECT_ELONG")
|
|
|
{
|
|
|
- double d = Convert.ToDouble(particles.Rows[i]["DELONG"]) / Convert.ToDouble(particles.Rows[i]["DMEAN"]);
|
|
|
+ double d = Convert.ToDouble(particlesFilter.Rows[i]["DELONG"]) / Convert.ToDouble(particlesFilter.Rows[i]["DMEAN"]);
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = Math.Round(d, 2);
|
|
|
}
|
|
|
- if (particles.Columns.Contains(enl.Current.Key))
|
|
|
+ if (particlesFilter.Columns.Contains(enl.Current.Key))
|
|
|
{
|
|
|
double num = 0;
|
|
|
- if (double.TryParse(particles.Rows[i][enl.Current.Key].ToString(), out num))
|
|
|
+ if (double.TryParse(particlesFilter.Rows[i][enl.Current.Key].ToString(), out num))
|
|
|
{
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = Math.Round(num, 2);
|
|
|
}
|
|
|
else if (enl.Current.Key == "Element")
|
|
|
{
|
|
|
List<string> elementtemp = new List<string>(ElementTypeSort);
|
|
|
- string[] strcbo = particles.Rows[i][enl.Current.Key].ToString().Split(';');
|
|
|
+ string[] strcbo = particlesFilter.Rows[i][enl.Current.Key].ToString().Split(';');
|
|
|
for (int j = 0; j < strcbo.Length; j++)
|
|
|
{
|
|
|
if (ElementTypeSort.Count == 0)
|
|
|
@@ -586,33 +585,33 @@ namespace OTSIncAReportGrids
|
|
|
else
|
|
|
{
|
|
|
double val = 0;
|
|
|
- if (double.TryParse(Convert.ToString(particles.Rows[i][enl.Current.Key]), out val))
|
|
|
+ if (double.TryParse(Convert.ToString(particlesFilter.Rows[i][enl.Current.Key]), out val))
|
|
|
{
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = val;
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = particles.Rows[i][enl.Current.Key];
|
|
|
+ dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = particlesFilter.Rows[i][enl.Current.Key];
|
|
|
}
|
|
|
|
|
|
}
|
|
|
}
|
|
|
if (enl.Current.Key == "TypeName")
|
|
|
{
|
|
|
- if (particles.Rows[i]["TypeId"].ToString() == "9")
|
|
|
+ if (particlesFilter.Rows[i]["TypeId"].ToString() == "9")
|
|
|
{
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = "Not Identified";
|
|
|
}
|
|
|
}
|
|
|
if (enl.Current.Key == "Equivalent")
|
|
|
{
|
|
|
- double dSize = Convert.ToDouble(particles.Rows[i]["Area"]);
|
|
|
+ double dSize = Convert.ToDouble(particlesFilter.Rows[i]["Area"]);
|
|
|
double Diameter = Math.Sqrt(dSize / Math.PI) * 2;
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells[k].Value = Math.Round(Diameter, 2);
|
|
|
}
|
|
|
if (enl.Current.Key == "Hardness")
|
|
|
{
|
|
|
- string str = ChangeHardnessColor(particles.Rows[i]["Hardness"].ToString());
|
|
|
+ string str = ChangeHardnessColor(particlesFilter.Rows[i]["Hardness"].ToString());
|
|
|
{
|
|
|
if (str == "#FF0000")
|
|
|
{
|
|
|
@@ -622,7 +621,7 @@ namespace OTSIncAReportGrids
|
|
|
}
|
|
|
if (enl.Current.Key == "AbPosX")
|
|
|
{
|
|
|
- Point point = CalculateParticleCenterPosition(result, new Point(Convert.ToInt32(particles.Rows[i]["SEMPosX"]), Convert.ToInt32(particles.Rows[i]["SEMPosY"])), new Point(Convert.ToInt32(particles.Rows[i]["PosX"]), Convert.ToInt32(particles.Rows[i]["PosY"])));
|
|
|
+ Point point = CalculateParticleCenterPosition(result, new Point(Convert.ToInt32(particlesFilter.Rows[i]["SEMPosX"]), Convert.ToInt32(particlesFilter.Rows[i]["SEMPosY"])), new Point(Convert.ToInt32(particlesFilter.Rows[i]["PosX"]), Convert.ToInt32(particlesFilter.Rows[i]["PosY"])));
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells["AbPosX"].Value = point.X;
|
|
|
dgV_ParticlesDevidePage.Rows[add_rowindex].Cells["AbPosY"].Value = point.Y;
|
|
|
}
|
|
|
@@ -1554,13 +1553,13 @@ namespace OTSIncAReportGrids
|
|
|
|
|
|
sheet2.AddMergedRegion(new NPOI.SS.Util.CellRangeAddress(1, 1, 1, 2000));
|
|
|
|
|
|
- for (int j = 0; j < particles.Rows.Count; j++)
|
|
|
+ for (int j = 0; j < particlesFilter.Rows.Count; j++)
|
|
|
{
|
|
|
row = sheet2.CreateRow(2 + j);
|
|
|
cell = row.CreateCell(0);
|
|
|
cell.CellStyle = cellStyle;
|
|
|
cell.SetCellValue(j + 1);
|
|
|
- var tmpPart = Particledata.GetParticleXrayDataByFidAndPid(particles.Rows[j]["fieldid"].ToString(), particles.Rows[j]["particleid"].ToString());
|
|
|
+ var tmpPart = Particledata.GetParticleXrayDataByFidAndPid(particlesFilter.Rows[j]["fieldid"].ToString(), particlesFilter.Rows[j]["particleid"].ToString());
|
|
|
if (tmpPart != null)
|
|
|
{
|
|
|
if (tmpPart.XrayId > -1)
|
|
|
@@ -1597,7 +1596,7 @@ namespace OTSIncAReportGrids
|
|
|
|
|
|
IDrawing drawing;
|
|
|
IClientAnchor anchor3;
|
|
|
- for (int j = 0; j < particles.Rows.Count; j++)
|
|
|
+ for (int j = 0; j < particlesFilter.Rows.Count; j++)
|
|
|
{
|
|
|
row = sheet3.CreateRow(j + 2);
|
|
|
row.Height = 120 * 20;
|
|
|
@@ -1791,7 +1790,7 @@ namespace OTSIncAReportGrids
|
|
|
return;
|
|
|
}
|
|
|
var SelectRows = dgV_ParticlesDevidePage.SelectedRows;
|
|
|
- uint[] Search_xray = new uint[2000];
|
|
|
+ uint[] Analysis_xray = new uint[2000];
|
|
|
if (SelectRows.Count != 0)
|
|
|
{
|
|
|
if (SelectRows.Count == 1)
|
|
|
@@ -1799,13 +1798,12 @@ namespace OTSIncAReportGrids
|
|
|
DataGridViewRow dgvr = SelectRows[0];
|
|
|
Bitmap ls_bp = (Bitmap)dgvr.Cells[2].Value;
|
|
|
List<string> list_str = (List<string>)ls_bp.Tag;
|
|
|
- uint[] Analysis_xray = new uint[2000];
|
|
|
int i_xray_id = 0;
|
|
|
List<Element> list_celementchemistryclr = new List<Element>();
|
|
|
- ReportFun.GetXrayByParticleTagIDAndFieldID_ForDrawDistrbutionImageAndBSE(Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Search_xray, out Analysis_xray, out i_xray_id, out list_celementchemistryclr);
|
|
|
+ ReportFun.GetXrayByParticleTagIDAndFieldID_ForDrawDistrbutionImageAndBSE(Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Analysis_xray, out i_xray_id, out list_celementchemistryclr);
|
|
|
}
|
|
|
}
|
|
|
- ListOfSimilarParticles Form_listOfSimilarParticles = new ListOfSimilarParticles(this, Search_xray, strings, m_ReportApp);
|
|
|
+ ListOfSimilarParticles Form_listOfSimilarParticles = new ListOfSimilarParticles(this, Analysis_xray, strings, m_ReportApp);
|
|
|
DialogResult result3 = Form_listOfSimilarParticles.ShowDialog();
|
|
|
if (result3 == DialogResult.OK)
|
|
|
{
|
|
|
@@ -2373,9 +2371,9 @@ namespace OTSIncAReportGrids
|
|
|
|
|
|
private void btn_showconfig_Click(object sender, EventArgs e)
|
|
|
{
|
|
|
- var p = particles; List<string> ele = new List<string>();
|
|
|
+ var p = particlesFilter; List<string> ele = new List<string>();
|
|
|
string elementsstr = "";
|
|
|
- foreach (DataRow row in particles.Rows)
|
|
|
+ foreach (DataRow row in particlesFilter.Rows)
|
|
|
{
|
|
|
string[] strcbo = row["Element"].ToString().Split(';');
|
|
|
for (int j = 0; j < strcbo.Length; j++)
|
|
|
@@ -2455,26 +2453,16 @@ namespace OTSIncAReportGrids
|
|
|
{
|
|
|
DataGridViewRow dgvr = SelectRows[0];
|
|
|
Bitmap ls_bp = (Bitmap)dgvr.Cells[2].Value;
|
|
|
- uint[] Search_xray = new uint[2000];
|
|
|
uint[] Analysis_xray = new uint[2000];
|
|
|
- int i_xray_id = 0;
|
|
|
- List<Element> list_celementchemistryclr = new List<Element>();
|
|
|
Particle particle=new Particle();
|
|
|
string str = " particleId= " + dgvr.Cells["particleId"].Value.ToString() + " and fieldid = " + dgvr.Cells["fieldid"].Value.ToString();
|
|
|
- DataRow[] drs = particles.Select(str);
|
|
|
+ DataRow[] drs = particlesFilter.Select(str);
|
|
|
DataRow row = drs[0];
|
|
|
- string subt = row["SubParticles"].ToString();
|
|
|
- if (subt != ""&& subt != null)
|
|
|
- {
|
|
|
- particle = Particledata.GetXrayByParticleTagIDAndFieldID_ForMergeParticle(Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Search_xray, out Analysis_xray);
|
|
|
- list_celementchemistryclr = particle.ElementList;
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- particle = ReportFun.GetXrayByParticleTagIDAndFieldID_ForDrawDistrbutionImageAndBSE(Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Search_xray, out Analysis_xray, out i_xray_id, out list_celementchemistryclr);
|
|
|
- }
|
|
|
+ string subParticleString = row["SubParticles"].ToString();
|
|
|
+ particle =Particledata.GetXrayByParticleIDAndFieldID(subParticleString, Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Analysis_xray);
|
|
|
+
|
|
|
|
|
|
- List<ShowElementInfo> list_showelementinfo = Particledata.GetShowElementInfos_ForMergeParticle(list_celementchemistryclr);
|
|
|
+ List<ShowElementInfo> list_showelementinfo = Particledata.GetShowElementInfos(particle.ElementList);
|
|
|
string str_IncAName = "";
|
|
|
str_IncAName = Convert.ToString(dgvr.Cells[1].Value);
|
|
|
if (particle == null)
|
|
|
@@ -2483,7 +2471,7 @@ namespace OTSIncAReportGrids
|
|
|
}
|
|
|
control_XRayTable1.SetParticleInfo("Area:" + Math.Round(particle.Area, 2) + " " + "DMAX:" + Math.Round(particle.DMAX, 2) + " " + "DELONG:" + Math.Round(particle.DELONG, 2) + " " + "DFERET:" + Math.Round(particle.DFERET, 2) + " " + "DINSCR:" + Math.Round(particle.DINSCR, 2) + "\n" + "DMEAN:" + Math.Round(particle.DMEAN, 2) + " " + "DMIN:" + Math.Round(particle.DMIN, 2) + " " + "DPERP:" + Math.Round(particle.DPERP, 2) + " " + "ORIENTATION:" + Math.Round(particle.ORIENTATION, 2) + " " + "PERIMETER:" + Math.Round(particle.PERIMETER, 2));
|
|
|
control_XRayTable1.Visible = true;
|
|
|
- control_XRayTable1.SetXRayShowLineValue(null, Analysis_xray, list_showelementinfo);
|
|
|
+ control_XRayTable1.SetXRayShowLineValue(Analysis_xray, list_showelementinfo);
|
|
|
control_XRayTable1.GBInfoStr = "";
|
|
|
control_XRayTable1.MaterialName = str_IncAName;
|
|
|
control_XRayTable1.List_ShowElementInfo = list_showelementinfo;
|
|
|
@@ -2496,19 +2484,19 @@ namespace OTSIncAReportGrids
|
|
|
int height = result.GetImageHeight();
|
|
|
Dictionary<string, List<Segment>> segsData = new Dictionary<string, List<Segment>>();
|
|
|
|
|
|
- if (subt == "" || subt == null)
|
|
|
+ if (subParticleString == "" || subParticleString == null)
|
|
|
{
|
|
|
int fldid = Convert.ToInt32(dgvr.Cells["fieldid"].Value);
|
|
|
int partid = Convert.ToInt32(dgvr.Cells["particleId"].Value);
|
|
|
var listseg = Particledata.GetSegmentData(fldid, partid);
|
|
|
string key = fldid.ToString() + "_" + partid.ToString();
|
|
|
segsData.Add(key, listseg);
|
|
|
- dataTable= particles.Clone();
|
|
|
+ dataTable= particlesFilter.Clone();
|
|
|
dataTable.ImportRow(row);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- string vs = "," + subt.Replace(':', '-') + ",";
|
|
|
+ string vs = "," + subParticleString.Replace(':', '-') + ",";
|
|
|
dataTable = Particledata.GetParticleAllForBig(vs);//组成拼接颗粒的子颗粒
|
|
|
foreach (DataRow dow in dataTable.Rows)
|
|
|
{
|
|
|
@@ -2519,8 +2507,8 @@ namespace OTSIncAReportGrids
|
|
|
segsData.Add(key, listseg);
|
|
|
}
|
|
|
}
|
|
|
- Bitmap bmap = fldImgAccess.GetBitmapForParticleAll(subt, dataTable, pix, height, width);
|
|
|
- Bitmap bmap1 = fldImgAccess.GetBitmapForParticleAllWithBlackAndWhite(subt, dataTable, segsData, pix, height, width);
|
|
|
+ Bitmap bmap = fldImgAccess.GetBitmapForParticleAll(subParticleString, dataTable, pix, height, width);
|
|
|
+ Bitmap bmap1 = fldImgAccess.GetBitmapForParticleAllWithBlackAndWhite(subParticleString, dataTable, segsData, pix, height, width);
|
|
|
control_XRayTable1.SetBitmapOfPictureBox(bmap1, bmap);
|
|
|
Invalidate();
|
|
|
ToolStripMenuItem_SimilarityReclassification.Enabled = true;
|
|
|
@@ -2632,7 +2620,6 @@ namespace OTSIncAReportGrids
|
|
|
return;
|
|
|
}
|
|
|
var SelectRows = dgV_ParticlesDevidePage.SelectedRows;
|
|
|
- uint[] Search_xray = new uint[2000];
|
|
|
|
|
|
DataGridViewRow dgvr = SelectRows[0];
|
|
|
Bitmap ls_bp = (Bitmap)dgvr.Cells[2].Value;
|
|
|
@@ -2642,18 +2629,18 @@ namespace OTSIncAReportGrids
|
|
|
List<Element> list_celementchemistryclr = new List<Element>();
|
|
|
|
|
|
string str = " particleId= " + dgvr.Cells["particleId"].Value.ToString() + " and fieldid = " + dgvr.Cells["fieldid"].Value.ToString();
|
|
|
- DataRow[] drs = particles.Select(str);
|
|
|
+ DataRow[] drs = particlesFilter.Select(str);
|
|
|
DataRow row = drs[0];
|
|
|
- string subt = row["SubParticles"].ToString();
|
|
|
- if (subt != "" && subt != null)
|
|
|
+ string subParticleString = row["SubParticles"].ToString();
|
|
|
+ if (subParticleString != "" && subParticleString != null)
|
|
|
{
|
|
|
- Particledata.GetXrayByParticleTagIDAndFieldID_ForMergeParticle(Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Search_xray, out Analysis_xray);
|
|
|
+ Particledata.GetXrayByParticleTagIDAndFieldID_ForMergeParticle(Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Analysis_xray);
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- ReportFun.GetXrayByParticleTagIDAndFieldID_ForDrawDistrbutionImageAndBSE(Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Search_xray, out Analysis_xray, out i_xray_id, out list_celementchemistryclr);
|
|
|
+ ReportFun.GetXrayByParticleTagIDAndFieldID_ForDrawDistrbutionImageAndBSE(Convert.ToInt32(dgvr.Cells["particleId"].Value), Convert.ToInt32(dgvr.Cells["fieldid"].Value), out Analysis_xray, out i_xray_id, out list_celementchemistryclr);
|
|
|
}
|
|
|
- ListOfSimilarParticles Form_listOfSimilarParticles = new ListOfSimilarParticles(this, Search_xray, m_ReportApp);
|
|
|
+ ListOfSimilarParticles Form_listOfSimilarParticles = new ListOfSimilarParticles(this, Analysis_xray, m_ReportApp);
|
|
|
DialogResult result3 = Form_listOfSimilarParticles.ShowDialog();
|
|
|
if (result3 == DialogResult.OK)
|
|
|
{
|