Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default Multiple values in Private Sub Worksheet_Change(ByVal Target As R

I've made it this far, but I need a little help. I've written the following
but I
would also like to look at column O for a value of "Trade".

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Application.Intersect(Range("q:q"), Target) Is Nothing Then
If Target.Value = "r" Or _
Target.Value = "w" Then
Range("t" & Target.Row).Select
End If
End If
End Sub
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,081
Default Multiple values in Private Sub Worksheet_Change(ByVal Target As R

In the same row?? If so:

If Target.Value = "r" Or Target.Value = "w" Then
if target.offset(0,-2).value = "Trade" then
Range("t" & Target.Row).Select
else
' what do you do if it isn't trade?
end if
End If


"davemon" wrote:

I've made it this far, but I need a little help. I've written the following
but I
would also like to look at column O for a value of "Trade".

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Application.Intersect(Range("q:q"), Target) Is Nothing Then
If Target.Value = "r" Or _
Target.Value = "w" Then
Range("t" & Target.Row).Select
End If
End If
End Sub

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default Multiple values in Private Sub Worksheet_Change(ByVal Target

Works like a charm. Thank you!
My brain doesn't hurt quite as much now.
Dave

"Duke Carey" wrote:

In the same row?? If so:

If Target.Value = "r" Or Target.Value = "w" Then
if target.offset(0,-2).value = "Trade" then
Range("t" & Target.Row).Select
else
' what do you do if it isn't trade?
end if
End If


"davemon" wrote:

I've made it this far, but I need a little help. I've written the following
but I
would also like to look at column O for a value of "Trade".

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Application.Intersect(Range("q:q"), Target) Is Nothing Then
If Target.Value = "r" Or _
Target.Value = "w" Then
Range("t" & Target.Row).Select
End If
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
Control Toolbox and Private Sub Worksheet_Change(ByVal Target As R [email protected] Excel Discussion (Misc queries) 1 August 17th 07 09:38 AM
Control Toolbox and Private Sub Worksheet_Change(ByVal Target As R Toppers Excel Discussion (Misc queries) 0 August 17th 07 02:02 AM
Control Toolbox and Private Sub Worksheet_Change(ByVal Target Toppers Excel Discussion (Misc queries) 0 August 17th 07 01:52 AM
ByVal Target Range Great Code but need Help Mark Excel Discussion (Misc queries) 31 July 27th 07 03:11 PM
Private Sub Worksheet_Change(ByVal Target As Excel.Range) [email protected] Excel Worksheet Functions 0 December 21st 06 02:13 AM


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

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"