Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3
Default Auto Dates

I am using Excel 2000 and this code in sheet 1 and it works fine. What I want
to do is change the range to A2 to M6. When I replace "A" with "A1:M6" it
will not work. Can anyone help me with this?

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
'when entering data in a cell in Col A
On Error GoTo enditall
Application.EnableEvents = False
If Target.Cells.Column = 1 Then
n = Target.Row
If IsNumeric(Excel.Range("A" & n).Value) And _
Excel.Range("A" & n).Value 1 Then
Excel.Sheets(2).Range("A" & n).Value = "paid" & Format(Now, "
mm/dd")
End If
End If
enditall:
Application.EnableEvents = True
End Sub
 
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
Auto dates chesjak Excel Worksheet Functions 2 June 4th 06 03:56 PM
Auto generated dates Fifi Excel Discussion (Misc queries) 1 March 31st 06 04:37 PM
Auto fill dates Jennifer Excel Worksheet Functions 0 March 24th 06 07:32 PM
auto posting dates maintchief New Users to Excel 1 October 28th 05 01:20 AM
Auto dates D Excel Worksheet Functions 0 June 22nd 05 06:01 PM


All times are GMT +1. The time now is 02:11 PM.

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"