S
SiriS
Hello,
I'm using excel 2002 and windows 2000 professional.
I am trying to dynamically create a "range string" for a range that
would like to select in a sheet. The range sometimes consists of 4
cells (not always following each other).
With a range string as in the following example I get an run-time erro
message during selection:
dim myRangeString as String
myRangeString="$J$15,$L$15,$N$15,$P$15,$Q$15,$S$15,$T$15,$U$15,$V$15,$W$15,$X$15,$Y$15,$Z$15,$AA$15,$AB$15,$AC$15,$AD$15,$AE$15,$AF$15,$AG$15,$AH$15,$AI$15,$AJ$15,$AK$15,$AL$15,$AM$15,$AN$15,$AO$15,$AP$15,$AQ$15,$AR$15,$AS$15,$AT$15,$AU$15,$AV$15,$AW$15,$AX$15,$AY$15,$AZ$15,$BA$15"
Range(myRangeString).Select
Why?
I suppose the range string is too long. Do I have to separate it in tw
parts? If so, how to select more than one range area at a moment?
Thanks,
Sir
I'm using excel 2002 and windows 2000 professional.
I am trying to dynamically create a "range string" for a range that
would like to select in a sheet. The range sometimes consists of 4
cells (not always following each other).
With a range string as in the following example I get an run-time erro
message during selection:
dim myRangeString as String
myRangeString="$J$15,$L$15,$N$15,$P$15,$Q$15,$S$15,$T$15,$U$15,$V$15,$W$15,$X$15,$Y$15,$Z$15,$AA$15,$AB$15,$AC$15,$AD$15,$AE$15,$AF$15,$AG$15,$AH$15,$AI$15,$AJ$15,$AK$15,$AL$15,$AM$15,$AN$15,$AO$15,$AP$15,$AQ$15,$AR$15,$AS$15,$AT$15,$AU$15,$AV$15,$AW$15,$AX$15,$AY$15,$AZ$15,$BA$15"
Range(myRangeString).Select
Why?
I suppose the range string is too long. Do I have to separate it in tw
parts? If so, how to select more than one range area at a moment?
Thanks,
Sir