Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Expanding a Selection
Hello
I want the user selection of cells to always select the whole row of selected cells but only starting from column B to column E. Selection.EntireRow.Select works well but i need to deselect some columns from this. any help would be great! Thanks Shorty |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Expanding a Selection
ActiveCell.Range("A1:C1,E1,G1,I1:J1,L1,N1").Select
or Range("A12:C12,E12,G12,J12:M12").Select You may have to fiddle with this to meet your requirements |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Expanding a Selection
In a module, add following subroutine:
Sub selBE() Range(Cells(ActiveCell.Row, "B"), Cells(ActiveCell.Row, "E")).Select End Sub Associate a shortcut (Ctrl-S for instance) HTH -- AP "Shorty" a écrit dans le message de oups.com... Hello I want the user selection of cells to always select the whole row of selected cells but only starting from column B to column E. Selection.EntireRow.Select works well but i need to deselect some columns from this. any help would be great! Thanks Shorty |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Expanding a Selection
wont that replace the user selected cells with predefinded range?
|
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Expanding a Selection
dim myRng as range
with activesheet set myrng = intersect(.range("b:e"),selection.entirerow) end with msgbox myrng.address Shorty wrote: Hello I want the user selection of cells to always select the whole row of selected cells but only starting from column B to column E. Selection.EntireRow.Select works well but i need to deselect some columns from this. any help would be great! Thanks Shorty -- Dave Peterson |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Expanding a Selection
Thanks, this one almost did it, the user can select multiple rows and
this only selects the last row in the selection. Range(Cells(ActiveCell.Row, "B"), Cells(ActiveCell.Row, "E")).Select but it selects the right columns which will come in useful!!! |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Expanding a Selection
ah ha fantastic this code does the trick. Selects the columns B to E
for the whole user selection. Thanks very much, problem solved in what, 17 mins, Thanks everyone! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Copy Selection - Transpose Selection - Delete Selection | Excel Discussion (Misc queries) | |||
Expanding Selection | Excel Discussion (Misc queries) | |||
sorting data and expanding the selection | Excel Discussion (Misc queries) | |||
Expanding Selection Range | Excel Programming | |||
expanding IF | Excel Programming |