Concentrating fields in controls

Concentrating fields in controls

Post by Stev » Sat, 03 Aug 2002 03:24:01



Hi All

Any help on this one much appreciated.

I have and ADP (XP) to SQL Server (2000).  On one particular form I want to
display address information in a single control in the form:

Steve
12 The Road
Townsville
UK
MD14 5TG

To do this in a single control I need to concentrate information from the
five fields into one field in the stored sproc/record source of the control.
I can do this no problem, but it's getting the line breaks that is proving
difficult.

I've tried using SELECT [Address1] + CHAR(13) + [Address2] + CHAR(13) +
[Town/City] etc ......

But in the control the CHAR(13) just displays as a box and no line return.
Anyone got any ideas on this one?  I would also like to build in the fact
that some of the fields may be null, therefore, I would want nothing
inserted and no line return???? !!!! ????

Steve

 
 
 

Concentrating fields in controls

Post by J Standl » Sat, 03 Aug 2002 23:19:23


Steve,

Try adding characters for CR and LF:

[Field1] + CHAR(13) + CHAR(10) + [Field2] + ...

Hope this helps.

~~ J Standlee

 
 
 

Concentrating fields in controls

Post by Stev » Sun, 04 Aug 2002 01:22:38


Thanks very much - That sorted is just fine!!

Steve


Quote:> Steve,

> Try adding characters for CR and LF:

> [Field1] + CHAR(13) + CHAR(10) + [Field2] + ...

> Hope this helps.

> ~~ J Standlee

 
 
 

1. Concentrating Fields

Hi All,

I have a table with loads of addresses in it in the form [Comp_Name],
[Mailing_Name], [Address1], [Address2], [Town/City], [Postcode[ etc etc etc.

What I want to do is combine these all into one field, ideally with a line
brake between each and call it say [Full_Address].

In Access I used to use the AddTextLine function, but can't find similar in
SQL 2000.

Any advice much appreciated.

Steve

2. SQL connection error.

3. Concentrating Fields!

4. Problem with TRIGGER

5. I/O: Spread it Out or Concentrate It?

6. Copy table via script

7. controlling field sizes via numeric field input?

8. What's wrong with my trigger?

9. Child fields - binding control to field

10. Help: Using the datarepeater control with an ActiveX control containing an embedded datacombo control

11. Persisting TimeStamp Field on a Web Page (for Concurrency Control)

12. Date fields via VB5 data control

13. field level security control