Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Help with suppression of part of string Post Reply Post New Topic
Author Message
Kwirky
Newbie
Newbie
Avatar

Joined: 21 Apr 2010
Online Status: Offline
Posts: 32
Quote Kwirky Replybullet Topic: Help with suppression of part of string
     Posted: 21 Apr 2010 at 9:03pm

Hello,
I have a report using Crystal Reports XI and I need to be able to supress part of a description.

We are using a tilda (~) to separate what we want to see from what we want suppressed.

So we have a description which says "Please do not leave in the driveway ~ stock valuable"

We want the document to only show "Please do not leave in the driveway".

Can anyone help with a suppression formula?

Many thanks
Joanne

IP IP Logged
FrnhtGLI
Senior Member
Senior Member
Avatar

Joined: 22 May 2009
Online Status: Offline
Posts: 347
Quote FrnhtGLI Replybullet Posted: 22 Apr 2010 at 2:33am

split({table.descripfield},'~')[1]

|< /\ '][' ( )
IP IP Logged
Kwirky
Newbie
Newbie
Avatar

Joined: 21 Apr 2010
Online Status: Offline
Posts: 32
Quote Kwirky Replybullet Posted: 22 Apr 2010 at 12:18pm
Hello FrnhtGLI.
I have tried your formula but am getting an error message
"a subscript must be between 1 and the size of the array"
 
I am a novice to this kind of formula so am not sure how to fix.
Thanks
Joanne
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 22 Apr 2010 at 3:50pm
left(table.description,instr(table.description,'~')-1)
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum