⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 subject_34719.htm

📁 一些关于vc的问答
💻 HTM
字号:
<p>
序号:34719 发表者:zhaiyl 发表日期:2003-04-01 15:13:09
<br>主题:小问题,送分了
<br>内容:我想在Edit控件里输出文件的内容,分几次输出,怎么弄呀<BR>用SetWindowText()行吗,如何处理每次都自动从头开始输出的问题呀。<BR>
<br><a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p>
<hr size=1>
<blockquote><p>
回复者:Merlin 回复日期:2003-04-01 15:43:17
<br>内容:SetSel<BR>ReplaceSel
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
<font color=red>答案被接受</font><br>回复者:极品青蛙 回复日期:2003-04-01 18:29:28
<br>内容:CEdit::SetSel <BR>void SetSel( DWORD dwSelection, BOOL bNoScroll = FALSE );<BR><BR>void SetSel( int nStartChar, int nEndChar, BOOL bNoScroll = FALSE );<BR><BR>Parameters<BR><BR>dwSelection<BR><BR>Specifies the starting position in the low-order word and the ending position in the high-order word. If the low-order word is 0 and the high-order word is –1, all the text in the edit control is selected. If the low-order word is –1, any current selection is removed.<BR><BR>bNoScroll<BR><BR>Indicates whether the caret should be scrolled into view. If FALSE, the caret is scrolled into view. If TRUE, the caret is not scrolled into view.<BR><BR>nStartChar<BR><BR>Specifies the starting position. If nStartChar is 0 and nEndChar is –1, all the text in the edit control is selected. If nStartChar is –1, any current selection is removed.<BR><BR>nEndChar<BR><BR>Specifies the ending position.<BR>/////////////////////////////////////////<BR>so you can use the CEdit::SetSel to select 你要的<BR>然后用CEdit::Copy&nbsp;&nbsp;CEdit::Paste<BR>
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:zhaiyl 回复日期:2003-04-01 23:54:06
<br>内容:谢谢了
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:zhaiyl 回复日期:2003-04-01 23:59:11
<br>内容:不好意思,我想我是没有说清楚我的意思,<BR>我是想把文件里的内容输出到Edit里。<BR>2楼的有时间在帮帮忙吧。
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:syosinsya 回复日期:2003-04-02 07:55:12
<br>内容:下面的方法可能很笨。<BR>为Edit控件设个CString型变量,设为m_MyEditStr,每次要更新时,先m_MyEditStr="",之后m_MyEditStr="234324\r\nwerewr..."(欲设的字符串);之后,UpdateData(FALSE).<BR>
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:Merlin 回复日期:2003-04-02 09:31:56
<br>内容:从文件读出数据,先用SetSel选到你要添的位置上然后用ReplaceSel写上去.
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:zhaiyl 回复日期:2003-04-02 14:12:13
<br>内容:多谢各位大侠的指点,小弟在这谢了
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -