#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 107
Default set rng=

hi guys
dim rng() as range
redim rng(1)
with active sheet
..cells(1,n).activate
for n= 1 to activesheet.rows.count
redim preserve rng(n)
rng(n) = .cells(1,n)
set rng(n)=activecell.entirecolumn
next n
will this work?
--
hemu
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default set rng=

dim rng() as range
redim rng(1 to activesheet.rows.count)
with active sheet
for n= 1 to activesheet.rows.count

set rng(n)=.Cells(n,1)

next n
End with

--
Regards,
Tom Ogilvy



"Hemant_india" wrote:

hi guys
dim rng() as range
redim rng(1)
with active sheet
.cells(1,n).activate
for n= 1 to activesheet.rows.count
redim preserve rng(n)
rng(n) = .cells(1,n)
set rng(n)=activecell.entirecolumn
next n
will this work?
--
hemu

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 107
Default set rng=

hi tom
is every element in an array a range object?
will i be able to use all ranges to manipulate the date containing these
ranges?
thanks
--
hemu


"Tom Ogilvy" wrote:

dim rng() as range
redim rng(1 to activesheet.rows.count)
with active sheet
for n= 1 to activesheet.rows.count

set rng(n)=.Cells(n,1)

next n
End with

--
Regards,
Tom Ogilvy



"Hemant_india" wrote:

hi guys
dim rng() as range
redim rng(1)
with active sheet
.cells(1,n).activate
for n= 1 to activesheet.rows.count
redim preserve rng(n)
rng(n) = .cells(1,n)
set rng(n)=activecell.entirecolumn
next n
will this work?
--
hemu

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 06:47 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"