IMPORTANT ANNOUNCEMENT

These forums were permanently set to read-only mode on July 20, 2022. From that day onwards, no new posting or comment is allowed on the site, but the historical content remains intact and searchable.

A new location for posting questions about PlanetPress Suite is now available:

OL Learn - PlanetPress Classic (opens in new tab)

Topic Options
#57677 - 09/14/20 06:04 AM Text wrapping
sau Offline
OL Newbie

Registered: 09/14/20
Posts: 2
Hi

I need to wrap the line based on "-" condition through a function any help would be great for me.

my data is in xml and line would be like English-عربك

Top
#57678 - 09/15/20 09:55 AM Re: Text wrapping [Re: sau]
Jean-Cédric Offline
OL Expert

Registered: 10/03/16
Posts: 681
Loc: Québec, Canada
Will there be any spaces as well in the sentences that you need be wrapping?
Do you wish the wrapping to apply as well on spaces (" ")?
_________________________
♪♫♪♫
99 frigging bugs in my code
99 frigging bugs
Take one down
Code around
127 frigging bugs in my code
♪♫♪♫

Top
#57681 - 09/15/20 04:46 PM Re: Text wrapping [Re: sau]
sau Offline
OL Newbie

Registered: 09/14/20
Posts: 2
no space not there only based on this "-" hyphen.

Top
#57684 - 09/16/20 09:33 AM Re: Text wrapping [Re: sau]
Jean-Cédric Offline
OL Expert

Registered: 10/03/16
Posts: 681
Loc: Québec, Canada
Code:
define(&theField,string,XmlGet('/PLANETPRESS_DATA_FILE[1]/CUSTOMER[1]/Company[1]'))

search(&theField,'-')
    show(&theField)
    crlf()
endsearch()

show(&theField)


Something like this worked for me. Of course, you will need to adapt with font and everything but that would do what you want.

You can refer to the Search() procedure to understand the code above.

Does that help?
_________________________
♪♫♪♫
99 frigging bugs in my code
99 frigging bugs
Take one down
Code around
127 frigging bugs in my code
♪♫♪♫

Top