+ Reply to Thread
Results 1 to 6 of 6

Excel 2007 Macros based off Data Validation list to populate rows

Hybrid View

  1. #1
    Registered User
    Join Date
    08-15-2012
    Location
    Las Vegas
    MS-Off Ver
    Excel 2010
    Posts
    87

    Re: Excel 2007 Macros based off Data Validation list to populate rows

    See the attached workbook.

    I put the following code in the sheet module where the data is.

    Private Sub Worksheet_Change(ByVal Target As Excel.Range)
    Dim ws As Worksheet
    
    Set ws = Application.ActiveSheet
    
    If Not Application.Intersect(Target, Range("C35")) Is Nothing Then
    
        If Range("C35").Value = "No" Then
            ws.Rows(37).Hidden = False
        Else
            ws.Rows(37).Hidden = True
        End If
    
    End If
    
    End Sub
    I also changed how the dropdowns are populate. I assigned cells K30, K31 and K32 as the source for the list. I did this to give the user the ability to select a blank value. The way the dropdown was in the original file had it so the cell started blank but once the user selected Yes or No they then had to use the delete key to reset the cell to blank.
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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