Results 1 to 2 of 2

Entering a condition into a Private Sub Worksheet_SelectionChange(ByVal Target As Range)

Threaded View

jonvanwyk Entering a condition into a... 03-06-2012, 01:16 PM
jonvanwyk Re: Entering a condition into... 03-06-2012, 01:19 PM
  1. #1
    Forum Contributor jonvanwyk's Avatar
    Join Date
    06-28-2010
    Location
    Iowa, USA
    MS-Off Ver
    Excel 2010
    Posts
    452

    Entering a condition into a Private Sub Worksheet_SelectionChange(ByVal Target As Range)

    I need the code below to add the condition that if F3 > 0 AND F5 = "Exempt", THEN MsgBox ....

    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    
    Application.Calculate
    If Sheets("Menu").Range("F3").Value > 0 Then
    
        MsgBox "As a salary-exempt employee, you are not entitled to overtime.  Please enter 0 into this field."
        
    End If
        
    End Sub
    Last edited by jonvanwyk; 03-06-2012 at 01:19 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1