Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Can anybody help me combine the 2 macros below:
Sub Macro1 () Sheets("FXMvt").Select For Each Cell In Range("O5:O119") If Cell.Value - 1 = Range("a1").Value Then Cell.Select End If Next If Range("A1").Value = Selection.Value - 1 Then MsgBox ("Tomorrow - Check for FX deal - Maturity date !!!") End If End Sub Sub Macro2 () Sheets("FXMvt").Select For Each Cell In Range("O5:O119") If Cell.Value = Range("a1").Value Then Cell.Select End If Next If Range("A1").Value = Selection.Value Then MsgBox ("Today - Check for FX deal - Maturity date !!!") End If End Sub thxs |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub Macro1 ()
Sheets("FXMvt").Select For Each Cell In Range("O5:O119") If Cell.Value - 1 = Range("a1").Value Then cell.Select MsgBox ("Tomorrow - Check for FX deal - Maturity date !!!") elseif Cell.Value = Range("a1").Value cell.Select MsgBox ("Today - Check for FX deal - Maturity date !!!") End If Next End Sub -- Regards, Tom Ogilvy "al007" wrote in message oups.com... Can anybody help me combine the 2 macros below: Sub Macro1 () Sheets("FXMvt").Select For Each Cell In Range("O5:O119") If Cell.Value - 1 = Range("a1").Value Then Cell.Select End If Next If Range("A1").Value = Selection.Value - 1 Then MsgBox ("Tomorrow - Check for FX deal - Maturity date !!!") End If End Sub Sub Macro2 () Sheets("FXMvt").Select For Each Cell In Range("O5:O119") If Cell.Value = Range("a1").Value Then Cell.Select End If Next If Range("A1").Value = Selection.Value Then MsgBox ("Today - Check for FX deal - Maturity date !!!") End If End Sub thxs |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
combine two macros | Excel Discussion (Misc queries) | |||
How do I combine MACROS and functions? | New Users to Excel | |||
Combine 2 macros into 1 Please. | Excel Programming | |||
combine two macros | Excel Worksheet Functions | |||
Combine 2 macros | Excel Programming |