Multiple "Range" with "Cells" property?

  • Thread starter Thread starter jopu
  • Start date Start date
J

jopu

Can below piece of code be converted to use the "Cells" property:

Code
-------------------
Range("B55:D55,I55").Selec
-------------------


I have a following piece of code used to determine range for a chart:

Code
 
Note to OP...

Be carefull with mixing qualified references and global references
to cells.

Set myrange = Worksheets("Chart").Range(Cells(startx, column),
Cells(weekx, column))

will pickup the GLOBAL cells (activesheet) NOT the cells of
Worksheets("chart")


use:

with worksheets("chart")
union( .cells(55,2).resize(,3),.cells(55,9))
end with



--
keepITcool
| www.XLsupport.com | keepITcool chello nl | amsterdam


Ron de Bruin wrote :
 

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

Back
Top