如何在不同的文本框上创建创建条件 [英] How to create create condition on different text box

查看:63
本文介绍了如何在不同的文本框上创建创建条件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的所有人

我正在C#和Sql Server 2005中创建一个项目.我在sql中有一个表,字段是名称,年龄,ph,添加.在C#中,我有一个表单,并有4个文本框.现在,我想在ase文本框中显示所有信息,如第一个文本框中,我将名称并按tab,然后在其他文本框中显示该名称的所有字段,如添加,ph,年龄和所有这些信息.请帮助我在第一个taext框的内部名称中创建此代码,然后在其他文本框中显示所有信息,例如在textbox2 show ph中显示,在textbox3 show age中...


请帮我如何创建这个...



Dear all

I am creating a project in C#, and Sql server 2005. i have a table in sql and the fields are name, age, ph, add. in the C# i have a form and have 4 text box. now i want to show all the information on thease text box like in first text box i will inter name and press tab then in other text box should show all the fields of that name like add, ph, age and all these information. Pleae help me to create this code in first taext box inter name and then show all the information in other text box like in text box2 show ph, in textbox3 show age......


Pleaes help me how to create this...



thanks in advance.

推荐答案

使用文本框的Leave事件.

http://msdn.microsoft.com/en-us/library/system.windows.forms.control.leave.aspx

请看下面的链接,以进行简单的"Ado.Net Select"操作.

http://mudassarkhan.wordpress.com/2009/01/10 /execute-sql-select-query-using-adonet/
Use Leave Event of your Textbox.

http://msdn.microsoft.com/en-us/library/system.windows.forms.control.leave.aspx

Have a look at below link for simple "Ado.Net Select" Operation.

http://mudassarkhan.wordpress.com/2009/01/10/execute-sql-select-query-using-adonet/


您可以使用 Jquery自动完成在选定的项目上搜索并填充所有文本框.
you may use Jquery Autocomplete Search and Fill all text box on select of items.


您可以为此目的使用AJAX ...

查看用于ASP.NET的AJAX
You may use AJAX for that purpose......

Check out AJAX for ASP.NET in code Project


这篇关于如何在不同的文本框上创建创建条件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆