DevExpress控件的MemoEdit中的GetPositionFromCharIndex() [英] GetPositionFromCharIndex() in MemoEdit of DevExpress control
本文介绍了DevExpress控件的MemoEdit中的GetPositionFromCharIndex()的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你好,
GetPositionFromCharIndex()是一种可用于在RichTextBox中查找光标的当前Location(X,Y)点的方法.但是我希望在DevExpress的MemoEdit中使用它.谁能帮助我找到如何在MemoEdit中获得光标位置,以便可以在该MemoEdit中将ListBox用作Intelisense.
在此先感谢.
Hello,
GetPositionFromCharIndex() is a method that we can use to find the current Location(X,Y) point of cursor in RichTextBox. But I want this to be used in MemoEdit of DevExpress. Can any one kindly help me to find how can i get the Cursor Position in MemoEdit so that i can use ListBox as Intelisense in that MemoEdit.
Thanks In Advance.
推荐答案
您可以使用此代码:
You could use this:
[DllImport("user32.dll")]
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool GetCaretPos(out Point lpPoint);
或直接使用SelectionStart
属性.
祝您好运!
Or simply use the SelectionStart
property.
Good luck!
我认为您应该直接在开发人员快速论坛中发布您的问题.在那里,您会发现更多使用相同组件的人.
看到这里:
http://community.devexpress.com/forums/ [
I think you should post your question directly in the developer express forums. There you''l find more people using the same components.
See here:
http://community.devexpress.com/forums/[^]
这篇关于DevExpress控件的MemoEdit中的GetPositionFromCharIndex()的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文