Normal Topic Multi Line field in a report (Read 555 times)
debmckee
Full Member
***
Offline



Posts: 123
Joined: Oct 5th, 2011
Multi Line field in a report
Dec 15th, 2011 at 7:12pm
Print Post Print Post  
Is there a way to make only line 1 of a multi line field to print in a report?
  
Back to top
 
IP Logged
 
lksseven
Full Member
***
Offline



Posts: 416
Location: Southwest
Joined: Jan 26th, 2009
Re: Multi Line field in a report
Reply #1 - Dec 16th, 2011 at 3:37am
Print Post Print Post  
If the field is, for example, 30 characters wide, perhaps:

vField = 0
vField = Field
vField = @Left(vField, 30)   
then
print vField

The variable grabs the contents of the field Field, and then @Left trims the variable to be only the first 30 characters - which is the first line of the multi line field.

(this is off the cuff while I'm watching something on TV.  If I'm striking out here, someone please squash me and steer Deb in the right direction).
  

Larry
Back to top
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: Multi Line field in a report
Reply #2 - Dec 16th, 2011 at 2:20pm
Print Post Print Post  
Hello,

You can also use
Code
Select All
Comments = Split(Comments, @Chr(10)) 


to get just the data on the first line.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
debmckee
Full Member
***
Offline



Posts: 123
Joined: Oct 5th, 2011
Re: Multi Line field in a report
Reply #3 - Dec 16th, 2011 at 5:32pm
Print Post Print Post  
Thanks Ray.  Worked like a charm.
  
Back to top
 
IP Logged
 
lksseven
Full Member
***
Offline



Posts: 416
Location: Southwest
Joined: Jan 26th, 2009
Re: Multi Line field in a report
Reply #4 - Dec 16th, 2011 at 6:57pm
Print Post Print Post  
Ray,

Oh, sweet - I'll use that myself!  Thanks.
  

Larry
Back to top
IP Logged