private void HilightRichText(RichTextBox control, string hilightString) { int nSelectStart = control.SelectionStart; int nSelectLength = control.SelectionLength; int nIndex = 0; while (nIndex < con
源码下载地址:http://download.csdn.net/detail/dora_zhh/7456521 1.如图所示,点击选择按钮弹出用户控件UserControl 2.点击确定按钮,将值传给winform页面中的textbox 3.UserControl1的代码: public partial class UserControl1 : UserControl { public UserControl1() { InitializeComponent(); } public delega
以前写winform 最多写几个文本框,最近需要入录一个人员信息,那好几十个字段,一下子干蒙了,这要是一个个取值赋值都写到明天了,于是就自己写了个方法,也不是什么高大上的,就是很简单很普通很low的方法. 废话少说上代码,注意,这块我就用了个文本框,你也可以找到所有控件,尽量控件name与实体字段一样. public Dictionary<string, object> GetRS_InfoVue() { var dic = new Dictionary<string, object&g
delegate void SetTextCallback(string text); private void showClientMsg(string text) { // InvokeRequired required compares the thread ID of the // calling thread to the thread ID of the creating thread. // If these threads are different, it returns tr