×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Space Alignment on second line of sentence

Space Alignment on second line of sentence

Space Alignment on second line of sentence

(OP)
Hello Experts,

When i pull text based value from a database field with bullets the space alignment on second line of sentence required . Formula which will help would be great . I am using crystal report 2013





Regards:
Bala

RE: Space Alignment on second line of sentence

Crystal is not very good with text formatting.

You can try two things

Use a formula to add the required HTML meta data to text and then view the formula as HTML, Format text to use HTML iterpretor

Or
Remove bullet points from text. Formula Mid (yourtextfield, 3, 1000) replace 1000 with max length of field.
Then just place text in a text box which is indented. Then using Wingdings add another text box which replicates the bullet style you want

Ian

RE: Space Alignment on second line of sentence

(OP)
Hi Ian,

Thanks for response. I may try your 1st point such as converting HTML meta data to text and view the formula as HTML.
The user copy a text of paragraph some with bullets from pdf or word then paste in a field which is a character type before paste user will change the phrases. This text i am trying to display again through PDF using crystal report. So when the displaying the sentence breaks to second line and third line based on length so now the starting word of second , third lines starts from margin without the space.

RE: Space Alignment on second line of sentence

(OP)
Hi Ian,

Tried the first option but it as no impact on spacing for subsequent line of a single sentence.

RE: Space Alignment on second line of sentence

(OP)
Hi Ian

I am trying for the space of subsequent lines.

RE: Space Alignment on second line of sentence

I know what you want but unfortunately I can not think of any other solution.

You could try using rtf interpretation but again I do not know if that supports indented bullets

Ian

RE: Space Alignment on second line of sentence

(OP)
Hi Ian,

thanks for support. Waiting if some could give a solution if they had come across same scenario.

regards:
Bala

RE: Space Alignment on second line of sentence

If bullets are not always there. Then I think the easiest solution is to standardise on NO Bullets. That is strip them out when present and solve the problem that way. Crystal is not really a document editor, its a report generator. Clue in the name (Crystal Reports).

I have produced some good customer documents for insurance companies but I have to work within the limitations of Crystal functionality.

Ian

RE: Space Alignment on second line of sentence

(OP)
Hi Ian,

I tried without formula and as per your earlier formula. still spacing in subsequent line is varying.

Without Formula


With Formula



Regards:
Bala

RE: Space Alignment on second line of sentence

Balaji,

Your formula output looks pretty good. I see that when the text wraps it is not indenting as far as you want. I think that is the issue you are having.

I wrestled with this and ended up coding my formula to break up the text into individual words in an array and then I determine how many words I can put on a line [based on a fixed line width I came up with]. Then, when I had to insert a break, I also inserted the tab character.

Here are some key pieces of my formula:

WrapLength := 100;
NumLFsBetweenBullets := 2;


// split text into array of words
word_array := split(text_field, " ");

WordCount := count(word_array);
For x := 1 To WordCount Do
(
new_text := new_text + word_array[x] + " ";
NewBulletLen := Length(new_bullet_text);
If x < WordCount then
(
If (NewBulletLen + Length(word_array[x+1]) - WrapLen) >= WrapLength then
(
WrapLen := NewBulletLen - Length(word_array[x+1]);
new_text := new_text + ChrW(13) + ChrW(9) + " ";
)
)
);

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close