Commit 657fdc85 几米阳光

去掉固定点信息,增加AOI程序配置

1 个父辈 b2aabcfe
...@@ -20,15 +20,15 @@ namespace URSoldering.DeviceLibrary ...@@ -20,15 +20,15 @@ namespace URSoldering.DeviceLibrary
/// 电路板ID /// 电路板ID
/// </summary> /// </summary>
public int boardId { get; set; } public int boardId { get; set; }
public string AoiFileName { get; set; }
/// <summary> /// <summary>
/// 条码 /// 条码
/// </summary> /// </summary>
public string WareCode { get; set; } public string WareCode { get; set; }
/// <summary> ///// <summary>
/// 机器人焊接时Z轴的高点 ///// 机器人焊接时Z轴的高点
/// </summary> ///// </summary>
public double ZHighValue { get; set; } //public double ZHighValue { get; set; }
/// <summary> /// <summary>
/// 工位编号,夹具编号(每一个程序需要配置四个夹具的位置,防止位置偏差) /// 工位编号,夹具编号(每一个程序需要配置四个夹具的位置,防止位置偏差)
...@@ -56,14 +56,14 @@ namespace URSoldering.DeviceLibrary ...@@ -56,14 +56,14 @@ namespace URSoldering.DeviceLibrary
/// 焊点列表 /// 焊点列表
/// </summary> /// </summary>
public List<WeldPointInfo> pointList { get; set; } public List<WeldPointInfo> pointList { get; set; }
/// <summary> ///// <summary>
/// 原点坐标X ///// 原点坐标X
/// </summary> ///// </summary>
public double originX { get; set; } //public double originX { get; set; }
/// <summary> ///// <summary>
/// 原点坐标Y ///// 原点坐标Y
/// </summary> ///// </summary>
public double originY { get; set; } //public double originY { get; set; }
/// <summary> /// <summary>
/// 图片名称 /// 图片名称
/// </summary> /// </summary>
...@@ -72,10 +72,10 @@ namespace URSoldering.DeviceLibrary ...@@ -72,10 +72,10 @@ namespace URSoldering.DeviceLibrary
/// 焊接预估时间 /// 焊接预估时间
/// </summary> /// </summary>
public double planNeedTime { get; set; } public double planNeedTime { get; set; }
/// <summary> ///// <summary>
/// 固定原点的位置,1=左上角,2=左下角,3=右上角,4=右下角 ///// 固定原点的位置,1=左上角,2=左下角,3=右上角,4=右下角
/// </summary> ///// </summary>
public int orgType { get; set; } //public int orgType { get; set; }
/// <summary> /// <summary>
/// 已经焊接次数,每次修改板子都会重置 /// 已经焊接次数,每次修改板子都会重置
/// </summary> /// </summary>
...@@ -125,38 +125,37 @@ namespace URSoldering.DeviceLibrary ...@@ -125,38 +125,37 @@ namespace URSoldering.DeviceLibrary
{ {
return myImage; return myImage;
} }
} }
public double getImageOrgX() //public double getImageOrgX()
{ //{
double orgX = originX; // double orgX = originX;
if (orgType == 2) // if (orgType == 2)
{ // {
orgX = originX + boardLength; // orgX = originX + boardLength;
} // }
else if (orgType == 4) // else if (orgType == 4)
{ // {
orgX = originX + boardLength; // orgX = originX + boardLength;
} // }
return orgX; // return orgX;
} //}
public double getImageOrgY() //public double getImageOrgY()
{ //{
double orgY = originY; // double orgY = originY;
if (orgType == 3) // if (orgType == 3)
{ // {
orgY = originY - boardWidth; // orgY = originY - boardWidth;
} // }
else if (orgType == 4) // else if (orgType == 4)
{ // {
orgY = originY - boardWidth; // orgY = originY - boardWidth;
} // }
return orgY; // return orgY;
} //}
} }
/// <summary> /// <summary>
......
...@@ -107,10 +107,10 @@ namespace URSoldering.DeviceLibrary ...@@ -107,10 +107,10 @@ namespace URSoldering.DeviceLibrary
LogUtil.info("加载产品配置:name=" + board.boardName + "为启动时的默认板子!"); LogUtil.info("加载产品配置:name=" + board.boardName + "为启动时的默认板子!");
CurrBoard = board; CurrBoard = board;
} }
if (board.orgType == 0) //if (board.orgType == 0)
{ //{
board.orgType = 1; // board.orgType = 1;
} //}
boardList.Add(board); boardList.Add(board);
} }
if (isUpdate) if (isUpdate)
......
...@@ -44,8 +44,10 @@ namespace URSoldering.Client ...@@ -44,8 +44,10 @@ namespace URSoldering.Client
{ {
try try
{ {
string filePath = Application.StartupPath + ConfigAppSettings.GetValue(Setting_Init.AOIFileConfig);
string path = Path.GetDirectoryName(filePath);
OpenFileDialog openfileDlg = new OpenFileDialog(); OpenFileDialog openfileDlg = new OpenFileDialog();
openfileDlg.InitialDirectory = path;
openfileDlg.Filter = "vscf files (*.vscf)|*.vscf"; openfileDlg.Filter = "vscf files (*.vscf)|*.vscf";
openfileDlg.FilterIndex = 1; openfileDlg.FilterIndex = 1;
openfileDlg.RestoreDirectory = true; openfileDlg.RestoreDirectory = true;
...@@ -67,8 +69,10 @@ namespace URSoldering.Client ...@@ -67,8 +69,10 @@ namespace URSoldering.Client
{ {
try try
{ {
string filePath = Application.StartupPath + ConfigAppSettings.GetValue(Setting_Init.AOIFileConfig);
string path = Path.GetDirectoryName(filePath);
SaveFileDialog savefileDlg = new SaveFileDialog(); SaveFileDialog savefileDlg = new SaveFileDialog();
savefileDlg.InitialDirectory = path;
savefileDlg.Filter = "ckcf files (*.vscf)|*.vscf"; savefileDlg.Filter = "ckcf files (*.vscf)|*.vscf";
savefileDlg.FilterIndex = 1; savefileDlg.FilterIndex = 1;
savefileDlg.RestoreDirectory = true; savefileDlg.RestoreDirectory = true;
......
...@@ -37,8 +37,6 @@ ...@@ -37,8 +37,6 @@
this.label1 = new System.Windows.Forms.Label(); this.label1 = new System.Windows.Forms.Label();
this.btnBack = new System.Windows.Forms.Button(); this.btnBack = new System.Windows.Forms.Button();
this.btnSave = new System.Windows.Forms.Button(); this.btnSave = new System.Windows.Forms.Button();
this.txtRobotZHighValue = new System.Windows.Forms.TextBox();
this.label9 = new System.Windows.Forms.Label();
this.txtBoardName = new System.Windows.Forms.TextBox(); this.txtBoardName = new System.Windows.Forms.TextBox();
this.label2 = new System.Windows.Forms.Label(); this.label2 = new System.Windows.Forms.Label();
this.label14 = new System.Windows.Forms.Label(); this.label14 = new System.Windows.Forms.Label();
...@@ -81,8 +79,6 @@ ...@@ -81,8 +79,6 @@
this.groupBox1.Controls.Add(this.label1); this.groupBox1.Controls.Add(this.label1);
this.groupBox1.Controls.Add(this.btnBack); this.groupBox1.Controls.Add(this.btnBack);
this.groupBox1.Controls.Add(this.btnSave); this.groupBox1.Controls.Add(this.btnSave);
this.groupBox1.Controls.Add(this.txtRobotZHighValue);
this.groupBox1.Controls.Add(this.label9);
this.groupBox1.Controls.Add(this.txtBoardName); this.groupBox1.Controls.Add(this.txtBoardName);
this.groupBox1.Controls.Add(this.label2); this.groupBox1.Controls.Add(this.label2);
this.groupBox1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.groupBox1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
...@@ -95,7 +91,7 @@ ...@@ -95,7 +91,7 @@
// //
// txtCode // txtCode
// //
this.txtCode.Location = new System.Drawing.Point(131, 96); this.txtCode.Location = new System.Drawing.Point(131, 98);
this.txtCode.MaxLength = 20; this.txtCode.MaxLength = 20;
this.txtCode.Name = "txtCode"; this.txtCode.Name = "txtCode";
this.txtCode.Size = new System.Drawing.Size(221, 23); this.txtCode.Size = new System.Drawing.Size(221, 23);
...@@ -104,7 +100,7 @@ ...@@ -104,7 +100,7 @@
// label1 // label1
// //
this.label1.AutoSize = true; this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(73, 100); this.label1.Location = new System.Drawing.Point(73, 102);
this.label1.Name = "label1"; this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(32, 17); this.label1.Size = new System.Drawing.Size(32, 17);
this.label1.TabIndex = 269; this.label1.TabIndex = 269;
...@@ -114,7 +110,7 @@ ...@@ -114,7 +110,7 @@
// //
this.btnBack.FlatAppearance.BorderSize = 0; this.btnBack.FlatAppearance.BorderSize = 0;
this.btnBack.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnBack.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnBack.Location = new System.Drawing.Point(224, 193); this.btnBack.Location = new System.Drawing.Point(224, 176);
this.btnBack.Name = "btnBack"; this.btnBack.Name = "btnBack";
this.btnBack.Size = new System.Drawing.Size(107, 37); this.btnBack.Size = new System.Drawing.Size(107, 37);
this.btnBack.TabIndex = 41; this.btnBack.TabIndex = 41;
...@@ -126,7 +122,7 @@ ...@@ -126,7 +122,7 @@
// //
this.btnSave.FlatAppearance.BorderSize = 0; this.btnSave.FlatAppearance.BorderSize = 0;
this.btnSave.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.btnSave.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.btnSave.Location = new System.Drawing.Point(91, 193); this.btnSave.Location = new System.Drawing.Point(111, 176);
this.btnSave.Name = "btnSave"; this.btnSave.Name = "btnSave";
this.btnSave.Size = new System.Drawing.Size(107, 37); this.btnSave.Size = new System.Drawing.Size(107, 37);
this.btnSave.TabIndex = 40; this.btnSave.TabIndex = 40;
...@@ -134,23 +130,6 @@ ...@@ -134,23 +130,6 @@
this.btnSave.UseVisualStyleBackColor = true; this.btnSave.UseVisualStyleBackColor = true;
this.btnSave.Click += new System.EventHandler(this.btnSave_Click); this.btnSave.Click += new System.EventHandler(this.btnSave_Click);
// //
// txtRobotZHighValue
//
this.txtRobotZHighValue.Location = new System.Drawing.Point(131, 142);
this.txtRobotZHighValue.Name = "txtRobotZHighValue";
this.txtRobotZHighValue.Size = new System.Drawing.Size(89, 23);
this.txtRobotZHighValue.TabIndex = 266;
this.txtRobotZHighValue.Text = "-20";
//
// label9
//
this.label9.AutoSize = true;
this.label9.Location = new System.Drawing.Point(65, 146);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(51, 17);
this.label9.TabIndex = 265;
this.label9.Text = "高位Z轴";
//
// txtBoardName // txtBoardName
// //
this.txtBoardName.Location = new System.Drawing.Point(132, 50); this.txtBoardName.Location = new System.Drawing.Point(132, 50);
...@@ -207,8 +186,6 @@ ...@@ -207,8 +186,6 @@
private System.Windows.Forms.Label label14; private System.Windows.Forms.Label label14;
private System.Windows.Forms.DataGridViewImageColumn dataGridViewImageColumn1; private System.Windows.Forms.DataGridViewImageColumn dataGridViewImageColumn1;
private System.Windows.Forms.DataGridViewImageColumn dataGridViewImageColumn2; private System.Windows.Forms.DataGridViewImageColumn dataGridViewImageColumn2;
private System.Windows.Forms.TextBox txtRobotZHighValue;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.TextBox txtCode; private System.Windows.Forms.TextBox txtCode;
private System.Windows.Forms.Label label1; private System.Windows.Forms.Label label1;
} }
......
...@@ -47,7 +47,7 @@ namespace URSoldering.Client ...@@ -47,7 +47,7 @@ namespace URSoldering.Client
txtBoardName.Text = newName; txtBoardName.Text = newName;
txtRobotZHighValue.Text = oldBoard.ZHighValue.ToString(); //txtRobotZHighValue.Text = oldBoard.ZHighValue.ToString();
} }
...@@ -64,10 +64,6 @@ namespace URSoldering.Client ...@@ -64,10 +64,6 @@ namespace URSoldering.Client
{ {
string newName = FormUtil.getValue(txtBoardName); string newName = FormUtil.getValue(txtBoardName);
string newCode = FormUtil.getValue(txtCode); string newCode = FormUtil.getValue(txtCode);
int newZHigh = FormUtil.GetIntValue(txtRobotZHighValue);
if (newName.Equals("")) if (newName.Equals(""))
{ {
MessageBox.Show("请输入程序名称"); MessageBox.Show("请输入程序名称");
...@@ -81,7 +77,6 @@ namespace URSoldering.Client ...@@ -81,7 +77,6 @@ namespace URSoldering.Client
return; return;
} }
BoardInfo newBoard = new BoardInfo(); BoardInfo newBoard = new BoardInfo();
//newBoard.boardCode = oldBoard.boardCode; //newBoard.boardCode = oldBoard.boardCode;
newBoard.boardId = BoardManager.GetNextId(); newBoard.boardId = BoardManager.GetNextId();
...@@ -96,11 +91,11 @@ namespace URSoldering.Client ...@@ -96,11 +91,11 @@ namespace URSoldering.Client
newBoard.solderingTime = oldBoard.solderingTime; newBoard.solderingTime = oldBoard.solderingTime;
newBoard.solderTime = oldBoard.solderTime; newBoard.solderTime = oldBoard.solderTime;
newBoard.imgName = oldBoard.imgName; newBoard.imgName = oldBoard.imgName;
newBoard.orgType = oldBoard.orgType; //newBoard.orgType = oldBoard.orgType;
newBoard.originX = oldBoard.originX; //newBoard.originX = oldBoard.originX;
newBoard.originY = oldBoard.originY; //newBoard.originY = oldBoard.originY;
newBoard.AoiFileName=oldBoard.AoiFileName;
newBoard.ZHighValue = newZHigh; //newBoard.ZHighValue = newZHigh;
try try
{ {
if (!oldBoard.imgName.Contains(oldBoard.boardName)) if (!oldBoard.imgName.Contains(oldBoard.boardName))
......
...@@ -197,16 +197,15 @@ namespace URSoldering.Client ...@@ -197,16 +197,15 @@ namespace URSoldering.Client
picBoard.Image = board.GetImage(); picBoard.Image = board.GetImage();
picBoard.Refresh(); picBoard.Refresh();
int orgType = board.orgType; //int orgType = board.orgType;
//double orgX = board.getImageOrgX();
double orgX = board.getImageOrgX(); //double orgY = board.getImageOrgY();
double orgY = board.getImageOrgY(); //Graphics grfx = picBoard.CreateGraphics();
Graphics grfx = picBoard.CreateGraphics();
//float preX = 0; //float preX = 0;
//float preY = 0; //float preY = 0;
int index = 0; //int index = 0;
foreach (WeldPointInfo weld in pointList) //foreach (WeldPointInfo weld in pointList)
{ //{
//float x = (float)Math.Abs(weld.PositionX - orgX) * picBoard.Width / width - pointHight / 2; //float x = (float)Math.Abs(weld.PositionX - orgX) * picBoard.Width / width - pointHight / 2;
//float y = (float)Math.Abs(weld.PositionY - orgY) * picBoard.Width / width - pointHight / 2; //float y = (float)Math.Abs(weld.PositionY - orgY) * picBoard.Width / width - pointHight / 2;
//g.FillEllipse(Brushes.Red, x - pointHight / 2, y - pointHight / 2, pointHight, pointHight); //g.FillEllipse(Brushes.Red, x - pointHight / 2, y - pointHight / 2, pointHight, pointHight);
...@@ -225,11 +224,11 @@ namespace URSoldering.Client ...@@ -225,11 +224,11 @@ namespace URSoldering.Client
//} //}
//preX = x; //preX = x;
//preY = y; //preY = y;
index++; //index++;
//g.FillEllipse(Brushes.Red, x, y, pointHight, pointHight); //g.FillEllipse(Brushes.Red, x, y, pointHight, pointHight);
} //}
g.Dispose(); //g.Dispose();
} }
private void FrmBoardList_Shown(object sender, EventArgs e) private void FrmBoardList_Shown(object sender, EventArgs e)
......
...@@ -50,10 +50,9 @@ namespace URSoldering.Client ...@@ -50,10 +50,9 @@ namespace URSoldering.Client
private void btnCodeTest_Click(object sender, EventArgs e) private void btnCodeTest_Click(object sender, EventArgs e)
{ {
FrmAOISetting frm = new FrmAOISetting(this);
//FrmAOISetting frm = new FrmAOISetting(this); this.Visible = false;
//this.Visible = false; frm.Show();
//frm.Show();
} }
private void btnCamera_Click(object sender, EventArgs e) private void btnCamera_Click(object sender, EventArgs e)
......
...@@ -65,7 +65,37 @@ namespace URSoldering.Client ...@@ -65,7 +65,37 @@ namespace URSoldering.Client
Robot.IsAutoRun = chbXunHuan.Checked; Robot.IsAutoRun = chbXunHuan.Checked;
LoadAOI(); LoadAOI();
} }
private bool IsLoad = false;
private void LoadAOI()
{
if (IsLoad)
{
return;
}
//位置配置到文件中
string appPath = Application.StartupPath;
string strFilePathName = ConfigAppSettings.GetValue(Setting_Init.AOIFileConfig);
string path2 = Path.GetDirectoryName(appPath + strFilePathName);
string filePath = path2 + @"\" + BoardManager.CurrBoard.AoiFileName;
if (File.Exists(filePath))
{
try
{
axCKVisionCtrl1.LoadConfigure(filePath);
axCKVisionCtrl1.ZoomView(2);
LogUtil.error("成功加载程序:" + BoardManager.CurrBoard.AoiFileName);
IsLoad = true;
}
catch (Exception ex)
{
LogUtil.error("加载程序【" + BoardManager.CurrBoard.AoiFileName + "】出错:" + ex.ToString());
}
}
else
{
LogUtil.error("未找到AOI程序文件:" + BoardManager.CurrBoard.AoiFileName);
}
}
private int ShowPointIndex = 5; private int ShowPointIndex = 5;
private void LoadCountPoint(bool isToday) private void LoadCountPoint(bool isToday)
{ {
...@@ -159,52 +189,10 @@ namespace URSoldering.Client ...@@ -159,52 +189,10 @@ namespace URSoldering.Client
solderCount = list[0].WeldPointCount; solderCount = list[0].WeldPointCount;
} }
} }
chartLine.Series[0].Points[ShowPointIndex - 1].SetValueY(weldCount); chartLine.Series[0].Points[ShowPointIndex - 1].SetValueY(weldCount);
chartSolder.Series[0].Points[ShowPointIndex - 1].SetValueY(solderCount); chartSolder.Series[0].Points[ShowPointIndex - 1].SetValueY(solderCount);
} }
private string aoiCheckFile = "";
private string currAOIFile = "";
private void LoadAOI()
{
//位置配置到文件中
string appPath = Application.StartupPath;
string strFilePathName = ConfigAppSettings.GetValue(Setting_Init.AOIFileConfig);
aoiCheckFile = appPath + strFilePathName;
LoadAOIFile(aoiCheckFile);
}
private bool LoadAOIFile(string filePath)
{
if (currAOIFile.Equals(filePath))
{
return true ;
}
if (File.Exists(filePath))
{
this.axCKVisionCtrl1.UnloadConfigure();
Thread.Sleep(100);
try
{
currAOIFile = filePath;
this.axCKVisionCtrl1.LoadConfigure(filePath);
this.axCKVisionCtrl1.ZoomView(2);
LogUtil.info("成功加载程序:" + filePath);
return true;
}
catch (Exception ex)
{
LogUtil.error("加载程序【" + filePath + "】出错:" + ex.ToString());
}
}
else
{
LogUtil.error("未找到AOI程序文件:" + filePath);
}return false;
}
private void LoadListPoint() private void LoadListPoint()
{ {
this.listPoint.Columns.Clear(); this.listPoint.Columns.Clear();
...@@ -618,97 +606,11 @@ namespace URSoldering.Client ...@@ -618,97 +606,11 @@ namespace URSoldering.Client
WeldRobotBean.StopWeld(); WeldRobotBean.StopWeld();
} }
} }
private void GetCode()
{
//try
//{
// this.label1.Text = "视觉/扫码";
// lblCodeResult.Text = "焊点自动识别中。。。";
// lblCodeResult.ForeColor = Color.Blue;
// lblCodeResult.Visible = true;
// LoadAOIFile(aoiCheckFile);
// //lblAOIResult.Visible = false;
// for (int i = 0; i < 5; i++)
// {
// bool result = RunAOI(2);
// //if (result)
// //{
// string code = getResult("Code",101);
// if (!code.Equals(""))
// {
// Robot.WareCode = code;
// lblCodeResult.ForeColor = Color.Blue;
// lblCodeResult.Text = "识别成功,共找到【" + BoardManager.CurrBoard.pointList.Count + "】个焊点";
// LogUtil.info("扫码成功:" + code);
// lblCodeResult.Visible = true;
// UpdateBoard(code);
// break;
// }
// else
// {
// lblCodeResult.ForeColor = Color.Red;
// lblCodeResult.Text = "焊点识别失败,即将重新识别";
// LogUtil.info("扫码失败,即将重新扫码");
// lblCodeResult.Visible = true;
// }
// //}
// Thread.Sleep(500);
// }
// lblCodeResult.ForeColor = Color.Blue;
// lblCodeResult.Text = "识别成功,共找到【" + BoardManager.CurrBoard.pointList.Count + "】个焊点";
// lblCodeResult.Visible = true;
// if (lblCodeResult.Visible.Equals(false))
// {
// lblCodeResult.ForeColor = Color.Blue;
// //lblCodeResult.Text = "扫码成功:1000001" ;
// LogUtil.info("扫码成功:1000001");
// }
//}
//catch (Exception ex)
//{
// LogUtil.error("读取条码出错:" + ex.ToString());
//}
}
private void UpdateBoard(string code)
{
//string[] str = code.Split('@');
//if (str.Length >= 1)
//{
// string boardCode = str[0];
// if (BoardManager.CurrBoard.WareCode.Equals(boardCode))
// {
// return;
// }
// else
// {
// BoardInfo board = BoardManager.getBoardByCode(boardCode);
// if (board == null)
// {
// LogUtil.error("条码【"+code+"】未找到匹配的程序,使用之前的程序【"+BoardManager.CurrBoard.boardName+"】");
// }
// else
// {
// LogUtil.error("条码【" + code + "】切换新程序【" + board.boardName + "】");
// BoardManager.UpdateCurrBoard(board.boardId);
// LoadPoint(board, -3);
// }
// }
//}
}
private void AOICheck() private void AOICheck()
{ {
try try
{ {
this.label1.Text = "视觉/光学检测"; this.label1.Text = "视觉/光学检测";
LoadAOIFile(aoiCheckFile);
lblCodeResult.Visible = false; lblCodeResult.Visible = false;
RunAOI(1); RunAOI(1);
int result = CKResult("Result",10); int result = CKResult("Result",10);
...@@ -786,29 +688,6 @@ namespace URSoldering.Client ...@@ -786,29 +688,6 @@ namespace URSoldering.Client
return 0; return 0;
} }
} }
//private string getResult(string name,int DataId)
//{
// string result = "";
// try
// {
// int idTool = axCKVisionCtrl1.GetTool(name);
// string value = "";
// object objValue = new VariantWrapper(value);
// if (axCKVisionCtrl1.GetValue(idTool, DataId, 0, ref objValue) == true)
// {
// result = objValue.ToString();
// }
// LogUtil.info("获取【" + name + "】:" + result);
// }
// catch (Exception ex)
// {
// LogUtil.error("获取【" + name + "】出错:" + ex.ToString());
// }
// return result;
//}
private void btnLook_Click(object sender, EventArgs e) private void btnLook_Click(object sender, EventArgs e)
{ {
FrmWorkCount frm = new FrmWorkCount(); FrmWorkCount frm = new FrmWorkCount();
......
...@@ -73,6 +73,12 @@ ...@@ -73,6 +73,12 @@
<Reference Include="System.Xml" /> <Reference Include="System.Xml" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="FrmAOISetting.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmAOISetting.designer.cs">
<DependentUpon>FrmAOISetting.cs</DependentUpon>
</Compile>
<Compile Include="FrmBase.cs"> <Compile Include="FrmBase.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
...@@ -109,12 +115,6 @@ ...@@ -109,12 +115,6 @@
<Compile Include="FrmProgramSelect.Designer.cs"> <Compile Include="FrmProgramSelect.Designer.cs">
<DependentUpon>FrmProgramSelect.cs</DependentUpon> <DependentUpon>FrmProgramSelect.cs</DependentUpon>
</Compile> </Compile>
<Compile Include="FrmCodeLearn.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmCodeLearn.Designer.cs">
<DependentUpon>FrmCodeLearn.cs</DependentUpon>
</Compile>
<Compile Include="FrmCamera.cs"> <Compile Include="FrmCamera.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
...@@ -183,6 +183,9 @@ ...@@ -183,6 +183,9 @@
</Compile> </Compile>
<Compile Include="Program.cs" /> <Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
<EmbeddedResource Include="FrmAOISetting.resx">
<DependentUpon>FrmAOISetting.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmBase.resx"> <EmbeddedResource Include="FrmBase.resx">
<DependentUpon>FrmBase.cs</DependentUpon> <DependentUpon>FrmBase.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
...@@ -201,9 +204,6 @@ ...@@ -201,9 +204,6 @@
<EmbeddedResource Include="FrmProgramSelect.resx"> <EmbeddedResource Include="FrmProgramSelect.resx">
<DependentUpon>FrmProgramSelect.cs</DependentUpon> <DependentUpon>FrmProgramSelect.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="FrmCodeLearn.resx">
<DependentUpon>FrmCodeLearn.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmCamera.resx"> <EmbeddedResource Include="FrmCamera.resx">
<DependentUpon>FrmCamera.cs</DependentUpon> <DependentUpon>FrmCamera.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!