how do I deselect cells within a range of cells

G

Guest

how do I deselect cells within a range of cells without deselecting the
entire range and reselect the desire cells?
 
R

RagDyer

Depending on how extensive and/or complicated your range is, you could try
to edit the range references in the "RefersTo" box of
<Insert> <Name> <Define>.
Click on the range name, then click in the "RefersTo" box, hit <F2>, and try
to make your changes.
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================

how do I deselect cells within a range of cells without deselecting the
entire range and reselect the desire cells?
 
D

Dave Peterson

I don't think that there's anything builtin to excel that will allow you to do
this.

But you could use a macro.

This deselects the activecell in a selection.

Option Explicit
Sub testme()

Dim myRng As Range
Dim myCell As Range

If Selection.Cells.Count = 1 Then
Exit Sub 'don't try to unselect
End If

For Each myCell In Selection.Cells
If myCell.Address = ActiveCell.Address Then
'do nothing
Else
If myRng Is Nothing Then
Set myRng = myCell
Else
Set myRng = Union(myCell, myRng)
End If
End If
Next myCell

myRng.Select

End Sub
 
G

Guest

I too have found this to be most frustrating! Most all other programs
including explorer allow you to deslect individual items by holding down the
ctrl key and clicking the item. Why didn't microsoft add this function into
excel is amazing.

I want to select a row of 100 items but not include about 10 cells ramdomly
placed throughout the selection. This would be so much more simple if I
could just deselect the individual cells after selecing all 100.
 
G

Guest

I too have found this to be most frustrating!!!

Windows Explorer allows you to select an entire list of items and then
deselect individual items by holding the ctrl key down and clicking the items
you wish to deselect.

Why does this not work in Excel???????

I have a list of 100 items and wish to deselect about 10 that are randomly
dispersed in the selection. This seems to such a simple thing, but I've
found no solution.
 
G

Gord Dibben

wagado

I will repeat my original answer this posting. Seems you missed it.

See this google search thread for Chip Pearson's "unselectcell" and
"unselectarea" code and how to implement it.

http://snipurl.com/9w8u


Gord Dibben 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