Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Jignesh Parekh
  Where is Jignesh Parekh?
 Rajkot
 India
 Jignesh Parekh
 To: Mike Gagnon
  Where is Mike Gagnon?
 Pointe Claire
 Canada
 Mike Gagnon
 Tags
Subject: RE: Formatting text in a Foxpro report
Thread ID: 109181 Message ID: 109201 # Views: 28 # Ratings: 0
Version: Visual FoxPro 9 Category: Reports and Printers
Date: Sunday, October 08, 2006 7:11:00 AM         
   


> Keon,
>
> You need to put a OLE picture control in the detail band (the footer band or the header band) of your report and point it to the general field (in this case gText) and use the following:
> (you can find the RTF tag definition here http://www.biblioscape.com/rtf15_spec.htm)
>
>
CLEAR ALL
> CLOSE DATABASES all 
> LOCAL lcStr  
> lcstr = "Note that there is a limit of 32 characters total for the sum of text."
> lcstr2 = "  Note this part need to be bolded and italicized."
> lcStr3 = "     Note this part needs to superscripted with a strikethru"
> CREATE cursor ctext (lctext m,lcText2 m,lcText3 m,gText g) 
> INSERT INTO ctext (lctext,lctext2,lcText3) VALUES (lcStr,lcStr2,lcStr3) 
> _rtfFile = "c:\"+SYS(3)+".rtf"  
> SCAN 
> 	   SET TEXTMERGE TO &_rtfFile NOSHOW
> 	   SET TEXTMERGE ON
> 	   \\{\rtf1 <<cText.lcText>>\b\i<<cText.lcText2>>\super\strike<<cText.lcText3>>}
> 	   SET TEXTMERGE TO
>    APPEND GENERAL gText FROM &_rtfFile CLASS "RICHTEXT.RICHTEXTCTRL.1" &&Class RTF
> ENDSCAN
> REPORT FORM C:\REPORT1.FRX PREVIEW NOCONSOLE
> 

>
>
> > > Someone recently (on another site) asked how to format a text in a single control in a Foxpro report. For example how to make part of the text bold, another part superscript with a strikethru and normal, all on one control. I thought I would share the result of my research this (this is done with and OLE picture control and RTF scripting)
> > >
> > >
> > >
> > > Mike Gagnon
> > >

> >
> > Mike,
> > dont be afraid to tell us more about this feauture....
> > Regards,
> > Koen

>
>
>
> Mike Gagnon
>



Thanks Mike, I was trying for it since a month I also posted it on this site and UT for solution and success, but not like this. Rating for you.

Jignesh

COMPLETE THREAD

Formatting text in a Foxpro report Posted by Mike Gagnon @ 10/7/2006 2:30:14 PM
RE: Formatting text in a Foxpro report Posted by Koen Piller @ 10/7/2006 2:50:37 PM
RE: Formatting text in a Foxpro report Posted by Mike Gagnon @ 10/7/2006 3:59:06 PM
RE: Formatting text in a Foxpro report Posted by Eric den Doop @ 10/7/2006 7:31:04 PM
RE: Formatting text in a Foxpro report Posted by Mike Gagnon @ 10/7/2006 7:57:42 PM
RE: Formatting text in a Foxpro report Posted by Jignesh Parekh @ 10/8/2006 7:11:00 AM
RE: Formatting text in a Foxpro report Posted by Mike Gagnon @ 10/8/2006 1:55:37 PM
RE: Formatting text in a Foxpro report Posted by Andy Kramek @ 10/7/2006 8:21:33 PM