Report Design
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Report Design
Message Icon Topic: Unbound string format Post Reply Post New Topic
Author Message
Enzyme80
Newbie
Newbie


Joined: 19 Jan 2007
Location: United States
Online Status: Offline
Posts: 27
Quote Enzyme80 Replybullet Topic: Unbound string format
    Posted: 28 Feb 2008 at 9:38am
if isnull({tlb1.IN2}) then
    {tlb1.CN} & "-" & {tlb1.IN}
else
    {tlb1.CN} & "-" & {tlb1.IN2}
 
CN, IN and IN2 are all numbers.
 
When I do the preview they show up as 1001-12345 or 1001-101 now when I put it on the web and and go to the page it shows up as 1,001.00-12,345.00 or 1,001.00-101.00.  I do not know where to format this.  When I just add the field to the report I can tell it how to display the number but when I do it as a string it formats it different in both sections.  I want it to show up as 1001-12345 or 1001-101
 
Thanks ahead of time.
 
IP IP Logged
Enzyme80
Newbie
Newbie


Joined: 19 Jan 2007
Location: United States
Online Status: Offline
Posts: 27
Quote Enzyme80 Replybullet Posted: 28 Feb 2008 at 10:58am
if isnull({tbl1.IN2}) then
    cstr({tbl1.CN},0,"") & "-" &  totext({tbl1.IN},0,"")
else
    totext({tbl1.CN},0,"") & "-" & totext({tbl1.IN2},0,"")
 
this gives me exactly what I need.
IP IP Logged
uarasss
Newbie
Newbie


Joined: 18 Jan 2012
Online Status: Offline
Posts: 4
Quote uarasss Replybullet Posted: 20 Mar 2012 at 9:55pm
ToText({P319.F2359}, 0, "") + " number" --> : 8500000 number

but my output should seem like this --> 8,500,000 number

can anyone know how to to this?
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 21 Mar 2012 at 7:54am
ToText({P319.F2359}, 0, ",") + " number" --> : 8500000 number
IP IP Logged
Post Reply Post New Topic
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



This page was generated in 0.016 seconds.