Dividing one column into two in a six-column table

T

Transcribe

I’m working with a six-column table in Word 2003. The first column has
surnames. The second column has first names for both men and women. For
women, the second column also has their maiden names between the characters
“[†and “]†if that info is known. Second column example: Mary [Smith].

Now the “powers that be†want that second column split into two columns
(becoming the second and third columns of the table but retaining all the
rest of the columns, making this then a seven-column table). The new second
column would have only the first names of all and the new third column would
have maiden names if there are maiden names. The old third column would then
become the new fourth column, etc. I found directions to split a single
column into two, but I cannot make this work for a single column within a
six-column table.

Making this a seven-column table may make this too large a table for
8-1/2-inch wide paper, but I’ll cross that bridge when I come to it! Any
suggestions would be greatly appreciated. I’m table challenged. A solution
would keep me from cutting and pasting on hundreds of pages of material.
 
M

macropod

Hi Transcribe,

For the new column, simply position the cursor at the right-hand end to the column you need to split and use Table|Insert|Column to
the Right. Depending on how your table is configured, Word will adjust all the column widths to accommodate the new column without
increasing the overall table width.
 
T

Transcribe

Thank you, Macropod. Your suggestion would give me the additional column, but
wouldn't it be blank? Is there an additional step I could take to make a mass
move of the data between the brackets [the maiden names] to the new column
keeping the maiden names in their original rows? I'm trying to avoid cutting
from the second column and pasting to the new third column the maiden names
from each and every line which has maiden names. Perhaps there's no easy way
to do this.


macropod said:
Hi Transcribe,

For the new column, simply position the cursor at the right-hand end to the column you need to split and use Table|Insert|Column to
the Right. Depending on how your table is configured, Word will adjust all the column widths to accommodate the new column without
increasing the overall table width.

--
Cheers
macropod
[Microsoft MVP - Word]


Transcribe said:
I’m working with a six-column table in Word 2003. The first column has
surnames. The second column has first names for both men and women. For
women, the second column also has their maiden names between the characters
“[†and “]†if that info is known. Second column example: Mary [Smith].

Now the “powers that be†want that second column split into two columns
(becoming the second and third columns of the table but retaining all the
rest of the columns, making this then a seven-column table). The new second
column would have only the first names of all and the new third column would
have maiden names if there are maiden names. The old third column would then
become the new fourth column, etc. I found directions to split a single
column into two, but I cannot make this work for a single column within a
six-column table.

Making this a seven-column table may make this too large a table for
8-1/2-inch wide paper, but I’ll cross that bridge when I come to it! Any
suggestions would be greatly appreciated. I’m table challenged. A solution
would keep me from cutting and pasting on hundreds of pages of material.

.
 
T

Transcribe

Suzanne, this looks like it has potential because it is similar to what I'm
trying to do. However, I now realize this column isn't as "pure" as I first
described it. The table is an index for obituaries, and sometimes there is
more than one "first name," such as when someone was better known by their
middle name. In that case, they put both first and middle name in this
column. There are other anomalies, as well. All maiden names are in the
brackets, though.

I will take a closer look at this suggested way to split the column
tomorrow, but I see problems with my comprehension already. I believe it may
have to do with the instructions being for Excel (...select the "Special"
button and choose "White space....?). I'm also not sure how to keyboard what
appear to be symbols in the instructions (a circumflex accent?). I have basic
skills at best.

Thank you, though, for directing me to what sounds like a very similar
situation.

Transcribe
 
M

macropod

Hi Transcribe,

Yes the column would be blank. If you've only got a few maiden names to process, it wouldn't take much effort to transfer them
manually. If you got many to process, you could use the following macro:

Sub Move_Maidens()
Dim oCel As Cell
Application.ScreenUpdating = False
With Selection
If Not .Information(wdWithInTable) Then Exit Sub
For Each oCel In .Tables(1).Columns(2).Cells
With oCel.Range.Find
.ClearFormatting
.Replacement.ClearFormatting
.Text = "\[[!\[\]]{1,}\]"
.Forward = True
.Wrap = wdFindStop
.Format = False
.MatchCase = False
.MatchWholeWord = False
.MatchAllWordForms = False
.MatchSoundsLike = False
.MatchWildcards = True
.Execute
If .Found = True Then
oCel.Next.Range.Text = .Parent.Text
.Parent.Delete
End If
End With
Next
End With
Application.ScreenUpdating = True
End Sub

Note that this macro will move any text between square brackets in the second column to the third column.

--
Cheers
macropod
[Microsoft MVP - Word]


Transcribe said:
Thank you, Macropod. Your suggestion would give me the additional column, but
wouldn't it be blank? Is there an additional step I could take to make a mass
move of the data between the brackets [the maiden names] to the new column
keeping the maiden names in their original rows? I'm trying to avoid cutting
from the second column and pasting to the new third column the maiden names
from each and every line which has maiden names. Perhaps there's no easy way
to do this.


macropod said:
Hi Transcribe,

For the new column, simply position the cursor at the right-hand end to the column you need to split and use Table|Insert|Column
to
the Right. Depending on how your table is configured, Word will adjust all the column widths to accommodate the new column
without
increasing the overall table width.

--
Cheers
macropod
[Microsoft MVP - Word]


Transcribe said:
I’m working with a six-column table in Word 2003. The first column has
surnames. The second column has first names for both men and women. For
women, the second column also has their maiden names between the characters
“[†and “]†if that info is known. Second column example: Mary [Smith].

Now the “powers that be†want that second column split into two columns
(becoming the second and third columns of the table but retaining all the
rest of the columns, making this then a seven-column table). The new second
column would have only the first names of all and the new third column would
have maiden names if there are maiden names. The old third column would then
become the new fourth column, etc. I found directions to split a single
column into two, but I cannot make this work for a single column within a
six-column table.

Making this a seven-column table may make this too large a table for
8-1/2-inch wide paper, but I’ll cross that bridge when I come to it! Any
suggestions would be greatly appreciated. I’m table challenged. A solution
would keep me from cutting and pasting on hundreds of pages of material.

.
 
S

Suzanne S. Barnhill

The instructions are for Word. The reference to Excel assumes that a data
source is in Excel, but if you're starting with Word, you can ignore that.
The instructions you mention are for Word's Find or Replace dialogs. You can
either type ^w (that is Shift+6, followed by w), or you can click More to
expand the dialog, then click Special and choose White Space, which will
insert ^w for you.

--
Suzanne S. Barnhill
Microsoft MVP (Word)
Words into Type
Fairhope, Alabama USA
http://word.mvps.org
 
T

Transcribe

Hello, again, Macropod,

Thank you so much for taking the time to write this macro. You say this
macro will move any text between square brackets in the second column to the
third column...and that's exactly what I need to do! I have read Help for
"Create a macro" and for "Run a macro," and I am having no luck making it
work. I'm unfamiliar with macros (having had my measly two MS Word classes
about 15 years ago). When I attempt to "run" the macro, it just puts the text
of the macro in my document. Yikes! It may take you too much time to lead me
through the steps to create and utilize this macro, as that may not be within
the scope of this discussion group.

Transcribe
 
M

macropod

Hi Transcribe,

OK. Here's how:
1. Open your document and press Alt-F11. This will open the vba environment.
2. In the left hand panel, select your document if it isn't already selected.
3. If you don't see a 'Modules' entry there, click Insert|Module. This will create a new vba module for you.
4. Copy & paste the macro from my post into the module.
5. You now have two choices - run the macro from here or go back to the document and run the macro from there.
. a) To run the macro from here, simply press F5.
. b) To run the macro from the document, press Alt-F11 again, then press Alt-F8 and choose the 'Move_Maidens' entry.
Note: In either case, the macro won't do anything if you the selection point isn't in the table.

From now on, you'll get a macro warning message when you open the document, but having the macro in it also means it's available to
anyone who works on this document. Running it multiple times won't do any harm - it simple processes whatever table the selection
point is in (you don't have to select the whole table), and moves any square-bracketed text from column2 to column3 (replacing
whatever else might have been in column3). If you don't want the macro warning message, you can instead insert the macro into the
'Normal' file that you should see at step 2 above. That makes the macro available to any file you've got open, but not to anyone
else whose got the table document open.

--
Cheers
macropod
[Microsoft MVP - Word]


Transcribe said:
Hello, again, Macropod,

Thank you so much for taking the time to write this macro. You say this
macro will move any text between square brackets in the second column to the
third column...and that's exactly what I need to do! I have read Help for
"Create a macro" and for "Run a macro," and I am having no luck making it
work. I'm unfamiliar with macros (having had my measly two MS Word classes
about 15 years ago). When I attempt to "run" the macro, it just puts the text
of the macro in my document. Yikes! It may take you too much time to lead me
through the steps to create and utilize this macro, as that may not be within
the scope of this discussion group.

Transcribe

macropod said:
Hi Transcribe,

Yes the column would be blank. If you've only got a few maiden names to process, it wouldn't take much effort to transfer them
manually. If you got many to process, you could use the following macro:

Sub Move_Maidens()
Dim oCel As Cell
Application.ScreenUpdating = False
With Selection
If Not .Information(wdWithInTable) Then Exit Sub
For Each oCel In .Tables(1).Columns(2).Cells
With oCel.Range.Find
.ClearFormatting
.Replacement.ClearFormatting
.Text = "\[[!\[\]]{1,}\]"
.Forward = True
.Wrap = wdFindStop
.Format = False
.MatchCase = False
.MatchWholeWord = False
.MatchAllWordForms = False
.MatchSoundsLike = False
.MatchWildcards = True
.Execute
If .Found = True Then
oCel.Next.Range.Text = .Parent.Text
.Parent.Delete
End If
End With
Next
End With
Application.ScreenUpdating = True
End Sub

Note that this macro will move any text between square brackets in the second column to the third column.
 
T

Transcribe

Greetings again, Macropod,

Thanks for this detailed procedure, but I’m not getting too far. After I do
step 1, what I see is (excuse my nontechnical terms) a new thingy with a
title bar that says “Normal – NewMacros (Code).†There are two drop-down
menus below this, dividing the next horizontal space: One says “(General)â€
and has no other drop-down choices. The other says “Macro1.†When I press the
down arrow on this one, the choices are: (Declarations), AveryWizard, Macro1,
Macro2, and WizardQuit. The big window below this second horizontal space has
what appears to be the macros for each of the second drop-down menu items.

In other words, under step 2, I don’t see a left hand panel in which to
select my document!

Might your instructions be either for Excel or for a version of Word other
than MS Office Word 2003 SP3, which is the one I have? (Sigh.) Thanks for
hanging in there with me.

Transcribe
 
M

macropod

Hi Transcribe,

Probably the easiest thing to do is to double-click on the 'New Macros' module below the 'Normal' entry, then add the macro I gave
you to the large panel to its right.
 

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