I am importing an .rtf doc using the rvActionOpen action into a DBRichViewEdit. The document is imported without errors, but the action does not place the table in edit mode. My dbaware post speedbutton is not enabled until I physically type in the DBRichViewEdit.
My attempt to add code (Table1.Edit) to the onclick event of the import button puts the table in edit mode, but then does not execute the richview action.
How do I do both, put the table in edit mode and execute the rvActionOpen richview action?
Placeing Table in Edit Mode
-
- Site Admin
- Posts: 17569
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
Yes, TrvActionOpen does not put table in an edit mode. It is because it uses "viewer-style" methods (Clear and LoadRTF) that do not put table in an edit mode, unlike "editing-style methods".
See http://www.trichview.com/help/idh_examp ... edit1.html
I do not recommend to use TrvActionOpen, TrvActionNew, TrvActionSave and TrvActionSaveAs with TDBRichViewEdit.
The problem you described can be solved by called table.Edit and DBRichViewEdit.Change in TrvActionOpen.OnOpenFile. But all these actions were designed to work using association between the editor and the file, which makes no sense for a DB component.
I suggest using only TrvActionInsertFile and TrvActionExport.
See http://www.trichview.com/help/idh_examp ... edit1.html
I do not recommend to use TrvActionOpen, TrvActionNew, TrvActionSave and TrvActionSaveAs with TDBRichViewEdit.
The problem you described can be solved by called table.Edit and DBRichViewEdit.Change in TrvActionOpen.OnOpenFile. But all these actions were designed to work using association between the editor and the file, which makes no sense for a DB component.
I suggest using only TrvActionInsertFile and TrvActionExport.