int start = richTextBox1.GetCharIndexFromPosition(new Point(0, 0)); int end = richTextBox1.GetCharIndexFromPosition(new Point(richTextBox1.ClientSize.Width, richTextBox1.ClientSize.Height-1)); var displayedText = richTextBox1.Text.Substring(start,end
public MainWindow() { InitializeComponent(); Run run = new Run("This is my text"); run.Foreground = new SolidColorBrush(Colors.Red); // My Color Paragraph paragraph = new Paragraph(); paragraph.Inlines.Add(run); run = new Run() { Text = "Th
DataView的RowFilter 实现过滤 根据文本框文字对datagridview的数据进行模糊查询, 其实也就是一个过滤 string qymc = textBox1.Text.ToString(); //获取文本框要模糊查询的文字 using (SQLiteConnection con = new SQLiteConnection(DATASOURCE)) { con.Open(); using (SQLiteCommand cmd = new SQLiteCommand()) { c
using Microsoft.Office.Interop.Word; using System; using System.Collections.Generic; using System.Drawing; using System.IO; using System.Linq; using System.Reflection; using System.Text.RegularExpressions; namespace OtaReportTool { public class WordH
T-SQL语句大全 --跳转到SQL myDemo USE [SQL myDemo] go --声明变量id declare @id int --为变量赋值:直接赋值 --将cid为3的cname值赋给变量@cn declare @cn varchar() --为变量赋值:查询赋值 select @cn = cname from classes where Cid = @id --输出[print:可直接输出'字符串'或变量]变量@cn if{} ===>if begin end print @