How can I create a single paragraph from standard statements?

C

Chris Mitchell

I have several text statements, each within its own cell, A1:A10

I want novice users to be able to pick and mix one or more of these, string
them together in any order, e.g. A2, A5, A1, in another cell (A15), then
edit that cell to link the statements into a single grammatically correct
paragraph.

Is this possible?

If Y how?

TIA

Chris.
 
P

Pete_UK

If each statement is a sentence in its own right, then you could do
this;

=A2&". "&A5&". "&A10&"."

Or, if you already have the full stop within the text:

=A2&" "&A5&" "&A10

Hope this helps.

Pete
 
C

Chris Mitchell

Thanks Pete.

I was aware of this, but I need something for novice users who have no
knowledge of this, and no inclination to learn it.

I was thinking something along the lines of a list from which users could
select as many statements as required, in the order they wanted them, then
some minor tweaking to make it into a grammatically correct paragraph.

I'm probably expecting too much, but you never know someone might know how.
 
M

MartinW

Hi Chris,

You could maybe label each statement like aaa, bbb, ccc etc.
Then set the auto correct, replace text as you type options like

aaa The quick brown
bbb fox jumps over
ccc the lazy dog

then aaa bbb ccc in a cell would return
The quick brown fox jumps over the lazy dog

I'm not sure but I think each replace box
should take up to 255 characters.

HTH
Martin
 
G

Gord Dibben

Chris

Can your users follow instructions and click on cells in the order they wish?

They can run this macro and select the cells in the order which gives them a
sentence, but not necessarily grammatically correct.

Sub ConCat_Cells()
Dim x As Range
Dim y As Range
Dim z As Range
Dim w As String
Dim sbuf As String
On Error GoTo endit
w = " "
Set z = Application.InputBox("Select Destination Cell", _
"Destination Cell", , , , , , 8)
Application.SendKeys "+{F8}"
Set x = Application.InputBox("Select Cells, Contiguous or Non-Contiguous", _
"Cells Selection", , , , , , 8)
For Each y In x
If Len(y.Text) > 0 Then sbuf = sbuf & y.Text & w
Next
z = Left(sbuf, Len(sbuf) - Len(w))
Exit Sub
endit:
MsgBox "Nothing Selected. Please try again."
End Sub


Gord Dibben MS Excel MVP
 

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