Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Possible to Separate Data With Tabs?

Status
Not open for further replies.

kc27

Technical User
Sep 10, 2008
171
US
I am using the formula below to concatenate data.

totext({store.store_id},"000")& " " & {store.store_nm}& " " & {store.store_addr_line_1}

It results in a report that is appears this way:

001 City Center Cleveland
002 Easttown Milwaukee

Is there a way for me to modify the report so the last portion of data (the city) will come out aligned as shown below rather than right after the store name?

001 City Center Cleveland
002 Easttown Milwaukee

Thanks in advance for any ideas on this
 
Do you know the maximum length of the store_nm field? Let's say that it is = 20 characters. Set up your formula like this:

stringvar pt2 := {store.store_nm};
totext({store.store_id},"000")& pt2 & space(20-len(pt2))&
{store.store_addr_line_1}

However, for this to work properly you need to use a nonproportional font, e.g., Courier New.

-LB
 
Thanks for the help.

I get this message: The number of copies of the string is too large or not an integer. The portion of the formula that below is highlighted.

space(20-len(pt2))

Is this what you meant by knowing the maximum length of the store_nm field?
 
How long can the name be? It is obviously longer than 20--which was just an example. Create a formula like this:

len({store.store_nm})

Place it in your detail section and insert a maximum on it at the grand total level. Then use a number a little higher than that in your formula in place of "20".

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top