Concatenation format breaks

S

SteveSuperRealtor

Given these text field inputs:
=[text68] & " MOM " & [ba] & " Bath(s)"


Is there a way to have a new sentence start on a new line between text68 and
Mom; and then have a new line to begin the ...[ba]& "Bath(s)" ...sections?

I guess what I am looking for is a "trick" to put a line break between these
elements. Text68 will be long and short sometimes, and I still want MOM to
show on the next available line (or even skip one line) and start as a new
section, but still reside within the original text box.
What I want is:
Text68
blank line
Mom
blank line
[ba]&" baths"
and have this all contained within one text box.

I have zero VBA experience (okay 0.5%) so please explain in simple terms if
possible. Thanks!
-Steve
 
D

Duane Hookom

You can add a carriage return/line feed with Chr(13) & Chr(10):
=[text68] & Chr(13) & Chr(10) & Chr(13) & Chr(10) & " MOM " & ...
 
S

SteveSuperRealtor

Worked like a charm! I've never seen or heard of that 13/10 combo before.
This is a tremendous help to me - thanks so much!
-Steve
--
Just bluffing it!


Duane Hookom said:
You can add a carriage return/line feed with Chr(13) & Chr(10):
=[text68] & Chr(13) & Chr(10) & Chr(13) & Chr(10) & " MOM " & ...

--
Duane Hookom
Microsoft Access MVP


SteveSuperRealtor said:
Given these text field inputs:
=[text68] & " MOM " & [ba] & " Bath(s)"


Is there a way to have a new sentence start on a new line between text68 and
Mom; and then have a new line to begin the ...[ba]& "Bath(s)" ...sections?

I guess what I am looking for is a "trick" to put a line break between these
elements. Text68 will be long and short sometimes, and I still want MOM to
show on the next available line (or even skip one line) and start as a new
section, but still reside within the original text box.
What I want is:
Text68
blank line
Mom
blank line
[ba]&" baths"
and have this all contained within one text box.

I have zero VBA experience (okay 0.5%) so please explain in simple terms if
possible. Thanks!
-Steve
 
S

SteveSuperRealtor

Incidentially, I neglected to mention that I am using Access2000.
Out of curiousity, I hit the help button and searched for "chr"
Never in a million years would I have found out about this trick using 2k
help.
Thanks again!
Here's the help from Access 2000: (reading it makes me feel even more
clueless! lol)

Chr Function and ChrB Function

The Chr function in Microsoft Access 7.0 always returns 2-byte characters.
In previous versions of Microsoft Access, Chr(&H41) and ChrB(&H41) were
equal, but in Microsoft Access 7.0, Chr(&H41) and ChrB(&H41) + ChrB(0) are
equal.

Also, in previous versions of Microsoft Access, "" was expressed as
ChrB(&H82) + ChrB(&HA0), but in Microsoft Access 7.0 it is expressed as
ChrB(&H42) + ChrB(&H30).

--
Just bluffing it!


SteveSuperRealtor said:
Worked like a charm! I've never seen or heard of that 13/10 combo before.
This is a tremendous help to me - thanks so much!
-Steve
--
Just bluffing it!


Duane Hookom said:
You can add a carriage return/line feed with Chr(13) & Chr(10):
=[text68] & Chr(13) & Chr(10) & Chr(13) & Chr(10) & " MOM " & ...

--
Duane Hookom
Microsoft Access MVP


SteveSuperRealtor said:
Given these text field inputs:
=[text68] & " MOM " & [ba] & " Bath(s)"


Is there a way to have a new sentence start on a new line between text68 and
Mom; and then have a new line to begin the ...[ba]& "Bath(s)" ...sections?

I guess what I am looking for is a "trick" to put a line break between these
elements. Text68 will be long and short sometimes, and I still want MOM to
show on the next available line (or even skip one line) and start as a new
section, but still reside within the original text box.
What I want is:
Text68
blank line
Mom
blank line
[ba]&" baths"
and have this all contained within one text box.

I have zero VBA experience (okay 0.5%) so please explain in simple terms if
possible. Thanks!
-Steve
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top