Dynamically obtaining a range from another range

  • Thread starter Thread starter Sharad Vyas
  • Start date Start date
S

Sharad Vyas

Hi all,
I have a user defined range, where i am loading the data to be plotted on
the chart. I used max. # of rows and Colmns that can ever be used on the
chart, in defining this range. As the data is populated I want to obtain the
range from this range, which should contain the noempty cells only. I will
know how many rows and columns in user defined range will be there for a
given scenario.What is the best way? Here is what I ideally desire:
MyRage - "A1 - E5" ( I defined this)
Loads data which has fills in "A1 - C3"
NewRange = MyRange.GetSomhow(A-1-C3")
Chart.SourceData = NewRange

Any thougths:
Thanks
-Sharad
 
Sharad,

Set NewRange = myRange.SpecialCells(xlCellTypeConstants)

HTH,
Bernie
MS Excel MVP
 
Hi Sharad,

Did Bernie's suggestion help you?
If you still have any concern, please feel free to pos there.

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 

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