Tabcontrol可以启用还是禁用? [英] Tabcontrol Can be Enable or Disable ?
本文介绍了Tabcontrol可以启用还是禁用?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我使用2 Tab控件。 1在另一个里面。那么我想要user_Id和密码,当这是真的,然后下一个标签页将打开或访问。
怎么可能?
I use 2 Tab control. 1 is inside the another. then i want user_Id & password , when this is true then next tab page will open or access.
how can it possible?
推荐答案
嗨亲爱的,
这只是问题。
Hi Dear,
This is simply problem.
if((UserId.Text == "ABC") && (Password.Text == "123")) // if Condition is true then tabControl1 enable is true Otherwise false.
{
tabControl1.Enabled = true;
}
else
{
tabControl1.Enabled = false;
}
private void button1_Click(object sender, RoutedEventArgs e)
{
if (textBox1.Text="" && textBox2.Text="")
{
tabControl2.IsEnabled = true;
}
}
这篇关于Tabcontrol可以启用还是禁用?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文