本文整理汇总了C#中Connector.InputBox方法的典型用法代码示例。如果您正苦于以下问题:C# Connector.InputBox方法的具体用法?C# Connector.InputBox怎么用?C# Connector.InputBox使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Connector
的用法示例。
在下文中一共展示了Connector.InputBox方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: btnScan_Click
private void btnScan_Click(object sender, EventArgs e)
{
js = new Connector(AccessRegistryTool.ReadValue("DBServer"), "Kids_Checkin", "kidschurch", "[email protected]");
string value = "";
bool passed = false;
if (js.InputBox("Check Out", "Please Scan Barcode", ref value) == System.Windows.Forms.DialogResult.OK)
{
string q = "SELECT * FROM tblKids WHERE fldStudentID = '" + value + "'";
js.ExecuteQuery(q);
js.RiD.Read();
if(!js.RiD.HasRows)
{
return;
}
string kidsid = js.RiD["fldID"].ToString();
for (int i=0;i<kID.Length;i++)
{
if(kidsid==kID[i])
{
passed = true;
break;
}
}
if(passed==true)
{
string p = js.GetPath() + "/Kids/" + js.RiD["fldPicture"];
string aID = js.Lookup("fldID", "tblAttendance", "fldKidsID='" + value + "' AND fldLoginDateTime BETWEEN '" + DateTime.Now.ToShortDateString() + " 00:00:00' AND '" + DateTime.Now.ToShortDateString() + " 23:59:59' AND (fldLogoutDateTime IS NULL)");
if (System.IO.File.Exists(p))
{
pbK1.Image = Image.FromFile(p);
}
lblKName.Text = "" + js.RiD["fldNickName"] + " " + js.RiD["fldLastName"];
lblBarcode.Text = value;
lblBirthday.Text = Convert.ToDateTime(js.RiD["fldBirthday"].ToString()).ToString("MM/dd/yyyy");
btnConfirm.Tag = aID;
btnConfirm.Enabled = true;
fromNFC = false;
}
else
{
lblNotification.ForeColor = Color.Red;
lblNotification.Text = "Fetcher and Kid Do Not Match";
}
}
}