If I open testrtf.rtf from testrtf I can see the file
but if I change and insert a word and close the window it ask me if I want save the file
I press ok and it ask me if "Do you want to overwrite it"
I press ok
when I reopen the file I cannot see nothing with testrtf.exe
because it save as text
if I open the file with windows notepad I can see the file as text and I saw it lose the format rtf
why ?
perhaps the METHOD SaveToFile is wrong ?
but if I change and insert a word and close the window it ask me if I want save the file
I press ok and it ask me if "Do you want to overwrite it"
I press ok
when I reopen the file I cannot see nothing with testrtf.exe
because it save as text
if I open the file with windows notepad I can see the file as text and I saw it lose the format rtf
why ?
perhaps the METHOD SaveToFile is wrong ?
METHOD SaveToFile( cFileName ) CLASS TRichEdit
DEFAULT cFileName := ::cFileName
if Empty( cFileName )
MsgAlert( "No filename provided to save the richedit text" )
return nil
endif
if File( cFileName )
if MsgYesNo( cFileName + " already exists" + CRLF + ;
"Do you want to overwrite it ?" )
MemoWrit( cFileName, ::GetText() )
endif
else
MemoWrit( cFileName, ::GetText() )
endif
return nilSince from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com