Hello!
first at all. I extend your TRichViewEdit. It reads text from database and save it to database, but now i have a problem with the undo/redo list.
Example:
I write an formated text and let it save to database. Now if i reopen my appliaction the text load successful. If i want to remove the text i set the cursor at the end and press backspace. At this moment i get the errRVUndoEmpty exception, because the undo list is empty.
I dont need the undo/redo list. So my question: Is it possible to completly disable this function?
TRichViewEdit: Disable undo/redo completly
-
- Site Admin
- Posts: 17555
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
Re: TRichViewEdit: Disable undo/redo completly
To disable undo, assign rve.UndoLimit=0.
errRVUndoEmpty occurs when some editing methods are called in a wrong context. Probably, you called undocumented methods. The best way perform backspace is
SendMessage(rve.TopLevelEditor.Handle, WM_KEYDOWN, VK_BACK, 0)
errRVUndoEmpty occurs when some editing methods are called in a wrong context. Probably, you called undocumented methods. The best way perform backspace is
SendMessage(rve.TopLevelEditor.Handle, WM_KEYDOWN, VK_BACK, 0)