Report Design
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Report Design
Message Icon Topic: Crystal Report textbox combination Post Reply Post New Topic
Author Message
Bouki
Newbie
Newbie


Joined: 12 Aug 2011
Online Status: Offline
Posts: 8
Quote Bouki Replybullet Topic: Crystal Report textbox combination
    Posted: 12 Aug 2011 at 6:49am
Hello.
Im new to C# and crystal report and i was wondering if i could get some help with this.
i create a crystal report form. in this code i have four textboxes. i want show this textboxes between another text which write in crystal report form. but i want this text show without any space.
my text shown like it: my name is Tom - - - - - - Block - - - - - -  from .....
but i want it show like this: my name is Tom Block from......
the textboxes size is variable.
(-) means space
i use vs 2008.net


Edited by Bouki - 12 Aug 2011 at 6:52am
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 12 Aug 2011 at 8:38am
"my name is " + trim({table.field1}) + " " + trim({table.field2} + " from "....
 
create a formula with the above and only populate 1 text box.
 
There is basically no way to resize and move a textbox...just not that dynamic.
 
The spaces are the extra room in the textbox, isn't?  If so, yeah, you can't move it....well you could move, but you don't know how 'big' to make it as there are no facilities to determine the width of the word.
 
Sorry couldn't be more help
IP IP Logged
Bouki
Newbie
Newbie


Joined: 12 Aug 2011
Online Status: Offline
Posts: 8
Quote Bouki Replybullet Posted: 12 Aug 2011 at 9:00am
Thanks for your attention.
Where i can do this:
 "my name is " + trim({table.field1}) + " " + trim({table.field2} + " from "....
IP IP Logged
Logle0917
Newbie
Newbie


Joined: 21 Jul 2011
Location: United States
Online Status: Offline
Posts: 14
Quote Logle0917 Replybullet Posted: 12 Aug 2011 at 9:50am
Triming the Field did the Trick Thank you so much!!!!!
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 12 Aug 2011 at 11:19am
you can create a formula, place the code in it.
 
then you can drag the formula onto the report and have it replace your 4 textboxes.
 
HTH
IP IP Logged
Bouki
Newbie
Newbie


Joined: 12 Aug 2011
Online Status: Offline
Posts: 8
Quote Bouki Replybullet Posted: 12 Aug 2011 at 6:49pm
Thanks.
its work perfect.
one more question how can bold part of the formula?
if i want display name bold.
"my name is " + trim({table.field1}) + " " + trim({table.field2} + " from "....

IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
Quote lockwelle Replybullet Posted: 15 Aug 2011 at 7:38am
while you can do that in a textbox, you can' t do that via a formula (at least not that I have seen...or been able to accomplish)
 
you could split it up into separate textboxes, but then you are back where you started :(
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 15 Aug 2011 at 11:36am
Put a text box on the report.  Start typing the first part.  Drag the field that you need for the first block into the text box, typed the next set of text, drag the next field into the box, etc. until you have your whole text block built.  Now select the first field in the text box and click on the Bold button.  Do the same for anything else that needs to be bold.
 
-Dell
 
Note: Crystal should automatically trim the fields that you drag into the text box.


Edited by hilfy - 15 Aug 2011 at 11:36am
IP IP Logged
Bouki
Newbie
Newbie


Joined: 12 Aug 2011
Online Status: Offline
Posts: 8
Quote Bouki Replybullet Posted: 17 Aug 2011 at 7:39am
text box means text object?
if yes: i do it but text object dont trim the fields which i put in to it.
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.032 seconds.