Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.tables
Kelly
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

I have built a table in Word 2003. The table has seven columns and many
rows. I wish to copy the contents of one cell to almost all the cells in a
column. The contents of the one cell has two paragraphs. I select the one
cell and click the copy button the toolbar. I then select all the cells
where I wish to paste the contents of the original cell. I click the paste
button on the toolbar. The results are odd. The first paragaph is pasted to
the first, third, fifth cell and so on. Every other cell receives the first
paragraph from the original cell starting with the first cell I selected to
receive the pasting. The second paragraph is pasted to the second, fourth,
sixth cell and so on. Every other cell receives the second paragraph from
the original cell starting with the second cell I select to receive the
pasting. I've tried everything I can think to do.

Is there an easy way to copy two paragraphs from one cell to multiple cells
with each cell receiving the contents of the original cell and not parsing
the contents of the orignail cell to many cells?

I appreciate any help you can provide.
  #2   Report Post  
Posted to microsoft.public.word.tables
Suzanne S. Barnhill
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

Bizarre! I would suggest this workaround. Replace the paragraph break in the
copied cell with, say, @@. Copy and paste, then use Find and Replace to
replace @@ with ^p in that column.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroup so
all may benefit.

"Kelly" wrote in message
...
I have built a table in Word 2003. The table has seven columns and many
rows. I wish to copy the contents of one cell to almost all the cells in

a
column. The contents of the one cell has two paragraphs. I select the

one
cell and click the copy button the toolbar. I then select all the cells
where I wish to paste the contents of the original cell. I click the

paste
button on the toolbar. The results are odd. The first paragaph is pasted

to
the first, third, fifth cell and so on. Every other cell receives the

first
paragraph from the original cell starting with the first cell I selected

to
receive the pasting. The second paragraph is pasted to the second,

fourth,
sixth cell and so on. Every other cell receives the second paragraph from
the original cell starting with the second cell I select to receive the
pasting. I've tried everything I can think to do.

Is there an easy way to copy two paragraphs from one cell to multiple

cells
with each cell receiving the contents of the original cell and not parsing
the contents of the orignail cell to many cells?

I appreciate any help you can provide.


  #3   Report Post  
Posted to microsoft.public.word.tables
Doug Robbins - Word MVP
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

If you select the whole cell and copy it, then paste to a range of cells,
everything will be pasted into those cells.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Kelly" wrote in message
...
I have built a table in Word 2003. The table has seven columns and many
rows. I wish to copy the contents of one cell to almost all the cells in
a
column. The contents of the one cell has two paragraphs. I select the
one
cell and click the copy button the toolbar. I then select all the cells
where I wish to paste the contents of the original cell. I click the
paste
button on the toolbar. The results are odd. The first paragaph is pasted
to
the first, third, fifth cell and so on. Every other cell receives the
first
paragraph from the original cell starting with the first cell I selected
to
receive the pasting. The second paragraph is pasted to the second,
fourth,
sixth cell and so on. Every other cell receives the second paragraph from
the original cell starting with the second cell I select to receive the
pasting. I've tried everything I can think to do.

Is there an easy way to copy two paragraphs from one cell to multiple
cells
with each cell receiving the contents of the original cell and not parsing
the contents of the orignail cell to many cells?

I appreciate any help you can provide.



  #4   Report Post  
Posted to microsoft.public.word.tables
Tony Jollans
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

Interesting. Word doesn't normally paste to multiple places at the same time
like Excel does. It seems to be trying to help but I don't know what it's
doing - with a single paragraph it seems to paste the first sentence oer and
over. I found that if I copied the whole cell rather than the text within
it, it worked as you want.

--
Enjoy,
Tony


"Kelly" wrote in message
...
I have built a table in Word 2003. The table has seven columns and many
rows. I wish to copy the contents of one cell to almost all the cells in

a
column. The contents of the one cell has two paragraphs. I select the

one
cell and click the copy button the toolbar. I then select all the cells
where I wish to paste the contents of the original cell. I click the

paste
button on the toolbar. The results are odd. The first paragaph is pasted

to
the first, third, fifth cell and so on. Every other cell receives the

first
paragraph from the original cell starting with the first cell I selected

to
receive the pasting. The second paragraph is pasted to the second,

fourth,
sixth cell and so on. Every other cell receives the second paragraph from
the original cell starting with the second cell I select to receive the
pasting. I've tried everything I can think to do.

Is there an easy way to copy two paragraphs from one cell to multiple

cells
with each cell receiving the contents of the original cell and not parsing
the contents of the orignail cell to many cells?

I appreciate any help you can provide.



  #5   Report Post  
Posted to microsoft.public.word.tables
Greg Maxey
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

If you really need just part of one cell pasted to multiple other selected
cells, then you will have to use a macro something like this:

Sub CopyPartOfOneCelltoSelectedCells()
Dim MyData As DataObject
Dim strClip As String
Dim oCell As Cell
Set MyData = New DataObject
MyData.GetFromClipboard
strClip = MyData.GetText
For Each oCell In Selection.Cells
oCell.Range.Text = strClip
Next
End Sub

See:
http://word.mvps.org/faqs/macrosvba/...eClipboard.htm



--
Greg Maxey/Word MVP
See:
http://gregmaxey.mvps.org/word_tips.htm
For some helpful tips using Word.


Doug Robbins - Word MVP wrote:
If you select the whole cell and copy it, then paste to a range of
cells, everything will be pasted into those cells.


"Kelly" wrote in message
...
I have built a table in Word 2003. The table has seven columns and
many rows. I wish to copy the contents of one cell to almost all
the cells in a
column. The contents of the one cell has two paragraphs. I select
the one
cell and click the copy button the toolbar. I then select all the
cells where I wish to paste the contents of the original cell. I
click the paste
button on the toolbar. The results are odd. The first paragaph is
pasted to
the first, third, fifth cell and so on. Every other cell receives
the first
paragraph from the original cell starting with the first cell I
selected to
receive the pasting. The second paragraph is pasted to the second,
fourth,
sixth cell and so on. Every other cell receives the second
paragraph from the original cell starting with the second cell I
select to receive the pasting. I've tried everything I can think to
do. Is there an easy way to copy two paragraphs from one cell to multiple
cells
with each cell receiving the contents of the original cell and not
parsing the contents of the orignail cell to many cells?

I appreciate any help you can provide.





  #6   Report Post  
Posted to microsoft.public.word.tables
Doug Robbins - Word MVP
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

Sure is bizarre! When I select and copy just the text of a cell containing
two paragraphs (not the whole cell), and then paste into multiple cells, in
each of the alternative cells is get just the first word of the alternate
paragraphs, not even the complete paragraph.

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

"Suzanne S. Barnhill" wrote in message
...
Bizarre! I would suggest this workaround. Replace the paragraph break in
the
copied cell with, say, @@. Copy and paste, then use Find and Replace to
replace @@ with ^p in that column.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the newsgroup
so
all may benefit.

"Kelly" wrote in message
...
I have built a table in Word 2003. The table has seven columns and many
rows. I wish to copy the contents of one cell to almost all the cells in

a
column. The contents of the one cell has two paragraphs. I select the

one
cell and click the copy button the toolbar. I then select all the cells
where I wish to paste the contents of the original cell. I click the

paste
button on the toolbar. The results are odd. The first paragaph is
pasted

to
the first, third, fifth cell and so on. Every other cell receives the

first
paragraph from the original cell starting with the first cell I selected

to
receive the pasting. The second paragraph is pasted to the second,

fourth,
sixth cell and so on. Every other cell receives the second paragraph
from
the original cell starting with the second cell I select to receive the
pasting. I've tried everything I can think to do.

Is there an easy way to copy two paragraphs from one cell to multiple

cells
with each cell receiving the contents of the original cell and not
parsing
the contents of the orignail cell to many cells?

I appreciate any help you can provide.




  #7   Report Post  
Posted to microsoft.public.word.tables
Greg Maxey
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

After further study, this might be better:

Sub CopyPartOfOneCelltoSelectedCells()
Dim MyData As DataObject
Dim oCell As Cell
Dim myString$
Set MyData = New DataObject
MyData.GetFromClipboard
myString = MyData.GetText
For Each oCell In Selection.Cells
If Asc(Right(myString, 2)) = 13 And Asc(Right(myString, 1)) = 10 Then
oCell.Range.Text = Left(MyData.GetText, Len(MyData.GetText) - 2)
Else
oCell.Range.Text = MyData.GetText
End If
Next
End Sub


--
Greg Maxey/Word MVP
See:
http://gregmaxey.mvps.org/word_tips.htm
For some helpful tips using Word.


Doug Robbins - Word MVP wrote:
If you select the whole cell and copy it, then paste to a range of
cells, everything will be pasted into those cells.


"Kelly" wrote in message
...
I have built a table in Word 2003. The table has seven columns and
many rows. I wish to copy the contents of one cell to almost all
the cells in a
column. The contents of the one cell has two paragraphs. I select
the one
cell and click the copy button the toolbar. I then select all the
cells where I wish to paste the contents of the original cell. I
click the paste
button on the toolbar. The results are odd. The first paragaph is
pasted to
the first, third, fifth cell and so on. Every other cell receives
the first
paragraph from the original cell starting with the first cell I
selected to
receive the pasting. The second paragraph is pasted to the second,
fourth,
sixth cell and so on. Every other cell receives the second
paragraph from the original cell starting with the second cell I
select to receive the pasting. I've tried everything I can think to
do. Is there an easy way to copy two paragraphs from one cell to multiple
cells
with each cell receiving the contents of the original cell and not
parsing the contents of the orignail cell to many cells?

I appreciate any help you can provide.



  #8   Report Post  
Posted to microsoft.public.word.tables
Greg Maxey
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

Doug,

Seems to me that the weirdness starts in the selection.copy process.

Anytime you include a paragraph mark Chr(13) in the middle of a selection,
the clipboard automatically creates a Chr(10) after that Chr(13) and appends
a Chr(13) and Chr(10) to the end of the string.

You can observe this with the following:

Sub Demo()
Dim MyData As DataObject
Dim myString$, ASCString$
Dim oCharNum&, i&
Set MyData = New DataObject
MyData.GetFromClipboard
myString = MyData.GetText
For i = 1 To Len(myString)
ASCString = ASCString & Asc(Mid(myString, i, 1)) & "|"
Next i
ASCString = Left(ASCString, Len(ASCString) - 1)
MsgBox ASCString

I typed

Test
Test
Test

In a cell and selected the middle word and ran that code. I expected
81|101|115|116|13. I got 81|101|115|116
Next, I selected the first two words "without" the paragraph mark following
the second word and ran that code.
I expected 81|101|115|116|13|81|101|115|116 what I got was
81|101|115|116|13|10|81|101|115|116|13|10
For some reason the clipboard changing the text. I assume that this may
have some effect on how the text is then pasted, but I haven't figured out
the relationship.


--
Greg Maxey/Word MVP
See:
http://gregmaxey.mvps.org/word_tips.htm
For some helpful tips using Word.


Doug Robbins - Word MVP wrote:
Sure is bizarre! When I select and copy just the text of a cell
containing two paragraphs (not the whole cell), and then paste into
multiple cells, in each of the alternative cells is get just the
first word of the alternate paragraphs, not even the complete
paragraph.

"Suzanne S. Barnhill" wrote in message
...
Bizarre! I would suggest this workaround. Replace the paragraph
break in the
copied cell with, say, @@. Copy and paste, then use Find and Replace
to replace @@ with ^p in that column.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the
newsgroup so
all may benefit.

"Kelly" wrote in message
...
I have built a table in Word 2003. The table has seven columns and
many rows. I wish to copy the contents of one cell to almost all
the cells in a column. The contents of the one cell has two
paragraphs. I select the one cell and click the copy button the
toolbar. I then select all the cells where I wish to paste the
contents of the original cell. I click the paste button on the
toolbar. The results are odd. The first paragaph is pasted

to
the first, third, fifth cell and so on. Every other cell receives
the first paragraph from the original cell starting with the first
cell I selected to receive the pasting. The second paragraph is
pasted to the second, fourth, sixth cell and so on. Every other
cell receives the second paragraph from
the original cell starting with the second cell I select to receive
the pasting. I've tried everything I can think to do.

Is there an easy way to copy two paragraphs from one cell to
multiple cells with each cell receiving the contents of the
original cell and not parsing
the contents of the orignail cell to many cells?

I appreciate any help you can provide.



  #9   Report Post  
Posted to microsoft.public.word.tables
Tony Jollans
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

I think this is normal copy behaviour. When you copy to the clipboard,
several different formats are put on the clipboard - reflected in the
various Paste Special options.

What is peculiar is the paste - as far as I know, multiple table cells is
the only instance of paste being targeted at multiple containers - in cases
of other multi-selections, paste is not available - Word seems to be trying
(and failing) to do something akin to what Excel does in similar
circumstances. It all works well when the copy source is one or more cells,
the attempted conversion just fails when the source is something else.

--
Enjoy,
Tony


"Greg Maxey" wrote in message
...
Doug,

Seems to me that the weirdness starts in the selection.copy process.

Anytime you include a paragraph mark Chr(13) in the middle of a selection,
the clipboard automatically creates a Chr(10) after that Chr(13) and

appends
a Chr(13) and Chr(10) to the end of the string.

You can observe this with the following:

Sub Demo()
Dim MyData As DataObject
Dim myString$, ASCString$
Dim oCharNum&, i&
Set MyData = New DataObject
MyData.GetFromClipboard
myString = MyData.GetText
For i = 1 To Len(myString)
ASCString = ASCString & Asc(Mid(myString, i, 1)) & "|"
Next i
ASCString = Left(ASCString, Len(ASCString) - 1)
MsgBox ASCString

I typed

Test
Test
Test

In a cell and selected the middle word and ran that code. I expected
81|101|115|116|13. I got 81|101|115|116
Next, I selected the first two words "without" the paragraph mark

following
the second word and ran that code.
I expected 81|101|115|116|13|81|101|115|116 what I got was
81|101|115|116|13|10|81|101|115|116|13|10
For some reason the clipboard changing the text. I assume that this may
have some effect on how the text is then pasted, but I haven't figured out
the relationship.


--
Greg Maxey/Word MVP
See:
http://gregmaxey.mvps.org/word_tips.htm
For some helpful tips using Word.


Doug Robbins - Word MVP wrote:
Sure is bizarre! When I select and copy just the text of a cell
containing two paragraphs (not the whole cell), and then paste into
multiple cells, in each of the alternative cells is get just the
first word of the alternate paragraphs, not even the complete
paragraph.

"Suzanne S. Barnhill" wrote in message
...
Bizarre! I would suggest this workaround. Replace the paragraph
break in the
copied cell with, say, @@. Copy and paste, then use Find and Replace
to replace @@ with ^p in that column.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
Word MVP FAQ site: http://word.mvps.org
Email cannot be acknowledged; please post all follow-ups to the
newsgroup so
all may benefit.

"Kelly" wrote in message
...
I have built a table in Word 2003. The table has seven columns and
many rows. I wish to copy the contents of one cell to almost all
the cells in a column. The contents of the one cell has two
paragraphs. I select the one cell and click the copy button the
toolbar. I then select all the cells where I wish to paste the
contents of the original cell. I click the paste button on the
toolbar. The results are odd. The first paragaph is pasted
to
the first, third, fifth cell and so on. Every other cell receives
the first paragraph from the original cell starting with the first
cell I selected to receive the pasting. The second paragraph is
pasted to the second, fourth, sixth cell and so on. Every other
cell receives the second paragraph from
the original cell starting with the second cell I select to receive
the pasting. I've tried everything I can think to do.

Is there an easy way to copy two paragraphs from one cell to
multiple cells with each cell receiving the contents of the
original cell and not parsing
the contents of the orignail cell to many cells?

I appreciate any help you can provide.





  #10   Report Post  
Posted to microsoft.public.word.tables
Greg
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

Tony,

It also seems to be version dependent. The results I reported
yesterday was from Word2003. Same test today in Word2000 the results
are totally different.

In 2000 the Chr(13) are not picked up even when present and the Chr(10)
is not appended.

Selecting the first word "Test" and the second word "Test" without the
paragraph mark returns:

84|101|115|116|84|101|115|116

So if I select "Test" Paragraph Mark "Test" the resultant .GetText
string is "TestTest." I wonder how Word then determines where to put
the paragraph mark back in that string when it performs a paste.

Obviously I am in an area over my head here.



  #11   Report Post  
Posted to microsoft.public.word.tables
Tony Jollans
 
Posts: n/a
Default Any way to copy two paragraphs from one cell to multiple cells?

It's no fun in the shallow end

If you look at the Edit Paste Special choices you will see that HTML is
the default (which I presume is what you get from Paste) but you are looking
at the Text from your DataObject. However, the Paste As Unformatted gives
different behaviour in 2000 and 2003. Getting way out of my depth too (I
suspect Graham Mayor may know something of this if he's watching) but I
think there have been changes in conversions to and from text formats
between releases.

An interesting side note - copying a couple of small paragraphs in 2000 (on
ME) gave me 45K of clipboard data. Roughly the same in 2003 (on XP) gave me
about 4.5K.

Have to go out for most of the rest of the day now but I will investigate
some more later.

--
Enjoy,
Tony


"Greg" wrote in message
oups.com...
Tony,

It also seems to be version dependent. The results I reported
yesterday was from Word2003. Same test today in Word2000 the results
are totally different.

In 2000 the Chr(13) are not picked up even when present and the Chr(10)
is not appended.

Selecting the first word "Test" and the second word "Test" without the
paragraph mark returns:

84|101|115|116|84|101|115|116

So if I select "Test" Paragraph Mark "Test" the resultant .GetText
string is "TestTest." I wonder how Word then determines where to put
the paragraph mark back in that string when it performs a paste.

Obviously I am in an area over my head here.



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Table cell does not break across columns [multi-col page] Charu Tevari Tables 1 February 14th 06 12:35 AM
How do I auto copy data from cell in a word table to another cell. Nev New Users 1 February 4th 05 08:51 PM
Does Ctrl button allow to select multiple paragraphs within a docu Kerevek Microsoft Word Help 3 January 8th 05 04:04 AM
copy cell to cell Tlogan Tables 1 January 5th 05 09:20 PM
Shading does not fill entire cell Fred Holmes Tables 1 October 28th 04 10:18 PM


All times are GMT +1. The time now is 08:05 PM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"