Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 47
Default Worksheet Change Method

in the appropriate sheet
Private Sub Worksheet_Change(ByVal Target As Range)
If ActiveCell.Address = "$A$21" Then
Rows(Target + 1 & ":15").Select
Selection.EntireRow.Delete
End If
End Sub

but this will move the value in cell A20 up into the data range (use A21 if
your user presses enter to move to next cell down

Private Sub Worksheet_Change(ByVal Target As Range)
If ActiveCell.Address = "$A$21" Then
Rows(Target + 1 & ":15").EntireRow.Select
Selection.ClearContents
Range("a20").Select
End If

End Sub
is a better bet

Steve


"Michael" wrote in message
...

Hello all,

Is is possible to maniputlate the Worksheet_Change_Method
to alter the struture of a range of cells ?. I have a
range of cells containing data say range(A1:G15).

I have a variable cell (A20) that is adjustable by the
user by entering a value from 1-15.

Now if the user enters a value of say 8 IN (A20), I would
like to delete rows(A9-A15)in the range (A1:G15), and if
it is 4, then rows (A5-A15)etc.

I hope that makes some sense or is it even possible ?

I have looked through the archives for deleting and
inserting cells, but cannot find what I am looking for.

Any help would be appreciated,

Thanks,

Michael



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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Best method for a monthly archive of a worksheet.. tim m Excel Discussion (Misc queries) 0 July 26th 06 04:19 PM
Drag down method for getting data from another worksheet at every Nth cell Bowbender Excel Worksheet Functions 5 September 22nd 05 03:55 AM
Best method of cloning the contents of a worksheet. Marie1uk Excel Worksheet Functions 2 July 6th 05 05:20 PM
Worksheet Change Method Michael[_10_] Excel Programming 0 July 25th 03 10:24 AM
Worksheet Change Method Don Guillett[_4_] Excel Programming 0 July 24th 03 06:44 PM


All times are GMT +1. The time now is 03:42 AM.

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"