Hi everybody,
I'm using the following code:
m_baustein:="example"
cmemo:=MemoRead(m_baustein)
//cmemo is "" instead of "example"
cmemo:=DC_GuiMemoEdit(cmemo,7,3,tiefe,weite+3)
// cmemo is the edited text
ok=MemoWrit(m_baustein,cmemo)
// of ist false, m_baustein is "example" instead of the text edited in memoedit()
1. What's wrong with my code?
2. Is it possible to change the font used in the DC_GuiMemoEdit()-Window?
use of memoedit doesn't work correctly
- obelix
- Posts: 48
- Joined: Tue Dec 03, 2013 7:44 am
- Location: Villingen-Schwenningen, Black Forest, Germany
use of memoedit doesn't work correctly
quiet old but still young and unskilled in express++
Re: use of memoedit doesn't work correctly
MemoRead expects a filename and returns it's contens. Is there a file named "example" (without extension)? I assume you're trying to edit the contens of "m_baustein" instead of the contens of a file called "example". Right?
DC_GuiMemoEdit works with "8.Courier" as the fixed editing font. You may just take the code for "DC_GuiMemoEdit" from _DCMEMOE.PRG (..\Source\DCLIPX), add it to your code, rename the function and replace font settings (search&replace "8.Courier").
DC_GuiMemoEdit works with "8.Courier" as the fixed editing font. You may just take the code for "DC_GuiMemoEdit" from _DCMEMOE.PRG (..\Source\DCLIPX), add it to your code, rename the function and replace font settings (search&replace "8.Courier").
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: use of memoedit doesn't work correctly
Code: Select all
m_baustein:="example"
cmemo:=DC_GuiMemoEdit(m_baustein,7,3,tiefe,weite+3)
* cMemo is the edited text, m_baustein is still "example"
* write to disk:
MemoWrit("c:\test\example.txt",cMemo)
Code: Select all
FUNCTION EditText(c)
LOCAL lOk := .F., cTextBackup := c
@ 0,0 DCMULTINE c SIZE 120,20 COMPATIBLE FONT "10.Arial"
DCREAD GUI ADDBUTTONS TO lOk TITLE 'Edit'
IF !lOk
c := cTextBackup
ENDIF
RETURN c
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
- obelix
- Posts: 48
- Joined: Tue Dec 03, 2013 7:44 am
- Location: Villingen-Schwenningen, Black Forest, Germany
Re: use of memoedit doesn't work correctly
Thank you Tom,
again and again it's you to give me the decisive advice.
DCMULTILINE is even more flexible and convenient to my problem.
Peter
again and again it's you to give me the decisive advice.
DCMULTILINE is even more flexible and convenient to my problem.
Peter
quiet old but still young and unskilled in express++
Re: use of memoedit doesn't work correctly

Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."