Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.tables
Hapless Hapless is offline
external usenet poster
 
Posts: 2
Default Count Number of Selected Cells In A Table?

Is there a way to determine how many cells have been selected in a table? We
work with very large tables of various sizes, from which we often have to
transfer data to a graphics layout application (Adobe InDesign) that just
isn't Word friendly. One of our compositors is working on a script to
translate tables into InDesign templates, and he tells me it would be helpful
for his purposes to know how many cells the user has selected, but that
doesn't seem to be something Word tells you.

Does Word provide this info in some place I don't know, or would it have to
be a macro-based solution? (If the latter, I'll repost to the VBA section.)

Thanks for your help!
  #2   Report Post  
Posted to microsoft.public.word.tables
macropod[_2_] macropod[_2_] is offline
external usenet poster
 
Posts: 2,059
Default Count Number of Selected Cells In A Table?

Hi Hapless,

You could use a macro like:
Sub SelectionCellCount()
If Selection.Information(wdWithInTable) Then _
MsgBox "Selection Cell Count: " & Selection.Cells.Count
End Sub

You could assign such a macro to a keyboard shortcut to facilitate its use.

--
Cheers
macropod
[MVP - Microsoft Word]


"Hapless" wrote in message ...
Is there a way to determine how many cells have been selected in a table? We
work with very large tables of various sizes, from which we often have to
transfer data to a graphics layout application (Adobe InDesign) that just
isn't Word friendly. One of our compositors is working on a script to
translate tables into InDesign templates, and he tells me it would be helpful
for his purposes to know how many cells the user has selected, but that
doesn't seem to be something Word tells you.

Does Word provide this info in some place I don't know, or would it have to
be a macro-based solution? (If the latter, I'll repost to the VBA section.)

Thanks for your help!

  #3   Report Post  
Posted to microsoft.public.word.tables
Hapless Hapless is offline
external usenet poster
 
Posts: 2
Default Count Number of Selected Cells In A Table?

Extremely helpful, macropod! I've passed the code on to the fellow writing
the script. Very cool!

Sorry about the delayed response, but I left work early yesterday. Thank you
so much!

"macropod" wrote:

Hi Hapless,

You could use a macro like:
Sub SelectionCellCount()
If Selection.Information(wdWithInTable) Then _
MsgBox "Selection Cell Count: " & Selection.Cells.Count
End Sub

You could assign such a macro to a keyboard shortcut to facilitate its use.

--
Cheers
macropod
[MVP - Microsoft Word]


"Hapless" wrote in message ...
Is there a way to determine how many cells have been selected in a table? We
work with very large tables of various sizes, from which we often have to
transfer data to a graphics layout application (Adobe InDesign) that just
isn't Word friendly. One of our compositors is working on a script to
translate tables into InDesign templates, and he tells me it would be helpful
for his purposes to know how many cells the user has selected, but that
doesn't seem to be something Word tells you.

Does Word provide this info in some place I don't know, or would it have to
be a macro-based solution? (If the latter, I'll repost to the VBA section.)

Thanks for your help!


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
how to automatic number cells in a table from bottom up? kathi Tables 1 August 18th 08 08:08 PM
how can I count the number of rows in an existing table roberto-cruz Tables 2 September 30th 07 10:41 AM
Count number of rows in table PamKT Microsoft Word Help 6 August 30th 06 09:32 AM
how do I resize selected cells in a table? Kati Tables 1 October 16th 05 09:05 PM
Count non-blank cells in a table column Bradley C. Hammerstrom New Users 4 December 14th 04 01:47 AM


All times are GMT +1. The time now is 05:39 AM.

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"