If I write the line " Mitch & Mary went to dinner" in a memo field, on screen it stores it, and displays it, correctly.
If I send it to the printer ( or even Preview ), it will print as "Mitch _ Mary went to dinner"
This occurs in the latest version of FWH, and is not present in the previous builds.
Problem with memo text printout
- TimStone
- Posts: 2954
- Joined: Fri Oct 07, 2005 1:45 pm
- Location: Trabuco Canyon, CA USA
- Has thanked: 25 times
- Been thanked: 2 times
- Contact:
Problem with memo text printout
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
- Antonio Linares
- Site Admin
- Posts: 42512
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Has thanked: 31 times
- Been thanked: 73 times
- Contact:
- TimStone
- Posts: 2954
- Joined: Fri Oct 07, 2005 1:45 pm
- Location: Trabuco Canyon, CA USA
- Has thanked: 25 times
- Been thanked: 2 times
- Contact:
Re: Problem with memo text printout
Antonio,
My clients don't write that way. It worked perfectly until the latest build of FWH. Anything in a memo field printed just like it was viewed on the screen.
My clients DO NOT LIKE CHANGE and so they are very upset with this right now. As programmers it might not be a big deal, but we write for our customers and their feelings matter.
Tim
My clients don't write that way. It worked perfectly until the latest build of FWH. Anything in a memo field printed just like it was viewed on the screen.
My clients DO NOT LIKE CHANGE and so they are very upset with this right now. As programmers it might not be a big deal, but we write for our customers and their feelings matter.
Tim
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
- James Bott
- Posts: 4840
- Joined: Fri Nov 18, 2005 4:52 pm
- Location: San Diego, California, USA
- Contact:
Re: Problem with memo text printout
Tim,
A quick fix would be to pre-print modify the TXT file by doing a search for "&" and replace it with "&&" before sending it to the printer.
Of course a better fix would be for the FW code to be fixed. Do you have software to do a file1 verses file2 comparison? That way you can find the changed code and post it here. If you don't have software for that I can point you to one.
James
A quick fix would be to pre-print modify the TXT file by doing a search for "&" and replace it with "&&" before sending it to the printer.
Of course a better fix would be for the FW code to be fixed. Do you have software to do a file1 verses file2 comparison? That way you can find the changed code and post it here. If you don't have software for that I can point you to one.
James
FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
- nageswaragunupudi
- Posts: 10721
- Joined: Sun Nov 19, 2006 5:22 am
- Location: India
- Been thanked: 8 times
- Contact:
Re: Problem with memo text printout
Thanks for pointing out. The problem is in the method SayText().
While methods Say(), cmSay() print the & character as expected, the method SayText() converts & as underscore of the next character (default behaviour of DrawTextEx()). This is bug in printer.prg and needs to be fixed.
But the problem is not new to the latest build. This behavior has been there in all builds from FWH1605 onwards till FWH1912. It might not have been noticed earlier but noticed now.
![Image](http://imagizer.imageshack.us/v2/xq90/924/5SqSF9.png)
Fix for this will be available in the next release.
Now this fix may be applied to the printer.prg of any existing versions in this way:
Please locate these lines (990 to 994 in fwh1912) in method SayText() of printer.prg:
Please modify these lines by adding 2 more parameters to FW_SayText() like this:
While methods Say(), cmSay() print the & character as expected, the method SayText() converts & as underscore of the next character (default behaviour of DrawTextEx()). This is bug in printer.prg and needs to be fixed.
But the problem is not new to the latest build. This behavior has been there in all builds from FWH1605 onwards till FWH1912. It might not have been noticed earlier but noticed now.
![Image](http://imagizer.imageshack.us/v2/xq90/924/5SqSF9.png)
Fix for this will be available in the next release.
Now this fix may be applied to the printer.prg of any existing versions in this way:
Please locate these lines (990 to 994 in fwh1912) in method SayText() of printer.prg:
Code: Select all | Expand
if lByRef
nRet := FW_SayText( ::hDCOut, @cText, aRect, cAlign, oFont, nClrText, nClrBack )
else
nRet := FW_SayText( ::hDCOut, cText, aRect, cAlign, oFont, nClrText, nClrBack )
endif
Please modify these lines by adding 2 more parameters to FW_SayText() like this:
Code: Select all | Expand
if lByRef
nRet := FW_SayText( ::hDCOut, @cText, aRect, cAlign, oFont, nClrText, nClrBack, nil, 0x800 )
else
nRet := FW_SayText( ::hDCOut, cText, aRect, cAlign, oFont, nClrText, nClrBack, nil, 0x800 )
endif
Regards
G. N. Rao.
Hyderabad, India
G. N. Rao.
Hyderabad, India
- TimStone
- Posts: 2954
- Joined: Fri Oct 07, 2005 1:45 pm
- Location: Trabuco Canyon, CA USA
- Has thanked: 25 times
- Been thanked: 2 times
- Contact:
Re: Problem with memo text printout
Thank you. I'll do the patch this morning.
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit