当前位置:网站首页>C RichTextBox controls the maximum number of rows
C RichTextBox controls the maximum number of rows
2022-06-23 07:58:00 【pcjiushizhu】
private void m_txtComment_TextChanged(object sender, EventArgs e)
{
int lines = m_txtComment.GetLineFromCharIndex(m_txtComment.Text.Length - 1); //m_txtComment.Lines.Length; // Row number
if(lines > maxLine - 1)
{
// The first 6 Position of the first word of the line
int my_index = m_txtComment.GetFirstCharIndexFromLine(maxLine);
// Keep only the first five lines
m_txtComment.Text = m_txtComment.Text.Substring(0, my_index - 1);
}
m_ri.CommentContent.Content = m_txtComment.Text;
m_txtComment.Select(m_txtComment.Text.Length, 0);
}
边栏推荐
- firewalld 配置文件的位置
- 深度学习------卷积(conv2D)底层
- Acwing game 56 [End]
- 套接字socket编程
- Matlab random volatility SV, GARCH using MCMC Markov chain Monte Carlo method to analyze exchange rate time series
- [Planet selection] how to efficiently build fine-grained two-way links between roam and thebrain?
- 浅析 Open API 设计规范
- 启动appium
- 忽略超长参数违规
- Learn to draw Er graph in an article
猜你喜欢

Create an orderly sequence table and perform the following operations: 1 Insert element x into the table and keep it in order; 2. find the element with the value of X, and delete it if found; 3. outpu

Imperva- method of finding regular match timeout

MIT CMS.300 Session 12 – IDENTITY CONSTRUCTION 虚拟世界中身份认同的建立 part 2

Test APK exception control nettraffic attacker development

The sandbox has reached a cooperation with football player to bring popular football cartoons and animation into the metauniverse

Acwing第 56 場周賽【完結】

PHP 文件包含 -ctf

Eureka服务注册与发现

HCIP之路MPLS

如何在conda虚拟环境开启jupyter-notebook
随机推荐
聊聊服务治理中的路由设计
快速排序 + 冒泡排序 + 插入排序 + 选择排序
11 字符串函数
Using jetpack datastore for data storage
domain controller
Unity to wechat applet games
three. Solution to stripe shadow and grid shadow in JS
启动appium
[try to hack] IP address
MySQL慢查询记录
Talk about routing design in service governance
MIT CMS. 300 session 12 – identity construction Part 2
PHP 文件包含 -ctf
分布式ID生成
MIT CMS.300 Session 12 – IDENTITY CONSTRUCTION 虚拟世界中身份认同的建立 part 2
Distributed ID generation
快手350014
Ers function display of SAP mm
socket编程——select模型
建立一有序的顺序表,并实现下列操作: 1.把元素x插入表中并保持有序; 2.查找值为x的元素,若找到将其删除; 3.输出表中各元素的值。