Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 31
Default Require data entry in column before moving to next cell

I found the following code which is exactly what I need but am unsure
how to change it to apply to all of Column A?


Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Set b9 = Range("B9")
Set t = Target
If Intersect(t, b9) Is Nothing Then
If checkit Then
If b9.Value = "" Then
Application.EnableEvents = False
b9.Select
Application.EnableEvents = True
Else
checkit = False
End If
End If
Else
checkit = True
End If
End Sub

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default Require data entry in column before moving to next cell

Maybe this

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.Column = 1 Then
MsgBox "Do Something"
End If
End Sub

Mike

" wrote:

I found the following code which is exactly what I need but am unsure
how to change it to apply to all of Column A?


Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Set b9 = Range("B9")
Set t = Target
If Intersect(t, b9) Is Nothing Then
If checkit Then
If b9.Value = "" Then
Application.EnableEvents = False
b9.Select
Application.EnableEvents = True
Else
checkit = False
End If
End If
Else
checkit = True
End If
End Sub


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
Require an entry in a cell Erika Excel Discussion (Misc queries) 3 September 25th 09 09:15 PM
Data Validation- Require Entry in a Field KrispyData Excel Discussion (Misc queries) 1 May 22nd 09 05:34 AM
Need ComboBox to require entry before moving to next control JennLee Excel Programming 7 May 4th 08 05:21 AM
How do I require data entry in a cell before moving to the next ce CindyB Excel Worksheet Functions 3 April 26th 08 04:18 PM
Require cell entry Bernie Deitrick Excel Programming 0 June 24th 04 02:43 PM


All times are GMT +1. The time now is 06:38 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"