Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #4  
Old 04-13-2020, 05:43 AM
macropod's Avatar
macropod macropod is offline Selection object and its Range property Windows 7 64bit Selection object and its Range property Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Quote:
Originally Posted by jpl View Post
Another subject of perplexity, it is this time about the relation between the Selection and Range objects inside a Word table (Table object).

...
First problem: the Range object contains six cells, but when it is selected, the selection contains only two instead of the six that one might hope for. When you select a Range in a Table object, it would seem that the selection is not the Range area, but a rectangular area based on the extreme cells of the Range.

If I select the first column, the Selection object contains two cells, the Plage object contains six, which is consistent with the previous result.
[I]Second problem: Sections 3 and 4 indicate that the Plage object contains 6 cells, but they only find 5 cells to display. Section 4 generates an error message indicating that the Plage.Cells (6) cell does not exist. What happened to my ghost cell?[/I
When you define a range within a table, the range goes horizontally from the first designated cell to the end of the row before going to the next row, starting at the first cell in that row, and so on, until the last designated cell is reached. This is quite unlike how a Selection works. As for the 'ghost' cell, you have encountered a Word VBA bug.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Distribute text in one cell across a range of cells (overcoming selection.range.cells.count bug) slaycock Word VBA 0 02-18-2017 07:00 AM
Selection object and its Range property Working with Selection.range. PRA007 Word VBA 2 02-19-2016 12:52 AM
Selection or Range Tommes93 Word VBA 1 04-10-2014 02:50 AM
Selection object and its Range property Use of Range Object Question jsb73 Word VBA 6 08-14-2012 07:35 PM
Cannot access most of property of MailItem object on Windows Server 2008 64 bit tz900 Outlook 0 04-10-2012 12:55 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 12:17 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft