Select Cells


Posted by Scott on January 02, 2002 3:13 PM

I have a column of cells numbered 1 through 100. I need to select all cells that are above 10. Could someone help me with the code for this? I'm sure it's pretty simple, but I just can't get my brain to work :)

Thanks

Posted by Or did you mean something more complex? Adam S. on January 02, 2002 3:30 PM

Range("A1:A9").Select (?) -nt.

Posted by Adam S. on January 02, 2002 3:31 PM

sorry, misread your post :P

Posted by Scott on January 02, 2002 3:37 PM

More Info

Thanks Adam. I do need something a little more complex. I have data on several pages in a workbook. On each page, the data is ranked 1-100 (not in order, but I could sort it). Some pages may not have less than 100. I only want to see the top 10 ranked on each page. However, there are calculations based off of the other data, so I don't want to delete that info, I just want to hide it. I thought that I could use VBA to select the cells, and then hide the rows. I'm just not sure how to get the code to select cells that contain numbers higher than 10.

Hope that's a little clearer. Any suggestions would be much appriciated!!

Scott



Posted by Juan Pablo G. on January 02, 2002 4:08 PM

Re: More Info

One easy solution would be to use another column, and test it

=A2>10

Then, use AutoFilter, and select either FALSE (Those less than 10) or TRUE (larger than 10)

Juan Pablo G. Adam. I do need something a little more complex. I have data on several pages in a workbook. On each page, the data is ranked 1-100 (not in order, but I could sort it). Some pages may not have less than 100. I only want to see the top 10 ranked on each page. However, there are calculations based off of the other data, so I don't want to delete that info, I just want to hide it. I thought that I could use VBA to select the cells, and then hide the rows. I'm just not sure how to get the code to select cells that contain numbers higher than 10.