LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default range selection problem

i have a sheet with bunches of data, i have a button when pressed t
copy the first 23 rows of data, opens a new sheet them copies it over
then i have to return the the first sheet and search for certain dat
to copy over as well. i have the code but for some reason th
original selected 23 rows stay selected, i even put

Range("A1").Select

to selecta cell to get rid of the highlighted stuf, then it searche
for the data and copies it, but some reason it doesnt highlight th
next set of data.

Range("A23:Q23").Select

this command selects a1 and copies that. i tell it not to though, here
what i have.

If (G23 1) Then Range("A23:Q23").Select
Selection.Copy
ActiveWindow.ActivateNext
ActiveWindow.WindowState = xlNormal
ActiveSheet.Range("A23:Q23").Select
ActiveSheet.Paste

End Sub

thats without the range("a1.... which would be right about IF.
is there somehting else i can put in to unselect the origina
highlighted data so it can then highlight something else. ive tried

Application.CutCopyMode = False

also. any ideas

--
Message posted from http://www.ExcelForum.com

 
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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Narrow Range based on Selection in Another Range David Excel Discussion (Misc queries) 3 July 1st 07 05:12 PM
Identifying a selection of a selection of a range swimfast Excel Worksheet Functions 1 March 1st 07 02:51 AM
Excel VBA - Range(Selection, Selection.End(xlDown)).Name issue. jonH Excel Programming 3 June 7th 04 09:13 PM
Creating range name for a range selection Mervyn Thomas Excel Programming 1 January 26th 04 05:18 PM
Range selection problem SotjeRuud Excel Programming 1 August 27th 03 12:41 PM


All times are GMT +1. The time now is 10:17 AM.

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

About Us

"It's about Microsoft Excel"