本文整理汇总了C#中System.Windows.Forms.TextBox.Equals方法的典型用法代码示例。如果您正苦于以下问题:C# TextBox.Equals方法的具体用法?C# TextBox.Equals怎么用?C# TextBox.Equals使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Windows.Forms.TextBox
的用法示例。
在下文中一共展示了TextBox.Equals方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: checkData
private bool checkData(TextBox textBox, Label label)
{
label.Text = "";
if (!textBox.Text.Equals(""))
{
if (textBox.Name.Equals("txtUsuarioModificarNombre") || textBox.Equals("txtUsuarioModificarContrasenia"))
{
if (!Util.todasLetras(textBox.Text))
{
label.Text = "Valor Incorrecto";
return false;
}
}
}
else
{
label.Text = "Vacio";
return false;
}
return true;
}
示例2: txtTime_Click
private void txtTime_Click(object sender, EventArgs e)
{
textBoxCurrent = sender as System.Windows.Forms.TextBox;
if (textBoxCurrent.Equals(txtHour))
{
ucTimeSelector.Items = hours;
}
else if (textBoxCurrent.Equals(txtMinute))
{
ucTimeSelector.Items = minutes;
}
else if (textBoxCurrent.Equals(txtSecond))
{
ucTimeSelector.Items = seconds;
}
else
{
return;
}
popUpControl.Show(textBoxCurrent, false);
textBoxCurrent.Focus();
if (!string.IsNullOrEmpty(textBoxCurrent.Text))
{
ucTimeSelector.SelectedValue = int.Parse(textBoxCurrent.Text);
}
}
示例3: TextBox_Click
private void TextBox_Click(object sender, EventArgs e)
{
m_cCurrentControl = (TextBox)sender;
if (m_cCurrentControl.Equals(PasswordTextBox) || m_cCurrentControl.Equals(ConfirmPassTextBox)) m_bInPassBox = true;
else m_bInPassBox = false;
m_pCursorPosition = Cursor.Current.HotSpot;
m_iSelectionIndex = m_cCurrentControl.SelectionStart;
}