Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
Is it possible to unhide a row based on the value of a cell? I am creating a questionnaire and would like to unhide a question if a certain answer is given. For example: Cell A1 - 'Question: Do you have a criminal record? Yes/No' If answer is Yes then a further question appears in B1 - 'Please provide details'. If answer was no then this will not appear. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
Assuming your Yes/No is a form button, then in the attached macro you would put Range("B1").EntireRow.Visible = True regards Paul chris wrote: Hi Is it possible to unhide a row based on the value of a cell? I am creating a questionnaire and would like to unhide a question if a certain answer is given. For example: Cell A1 - 'Question: Do you have a criminal record? Yes/No' If answer is Yes then a further question appears in B1 - 'Please provide details'. If answer was no then this will not appear. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() You can program this in your thisWorkbook module as an event handler procedure Private Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target As Range) If ActiveSheet.Range("a1").Value = "Yes" Then ActiveSheet.Range("a2").EntireRow.Hidden = False End If End Sub |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Paul - I was just planning on using a drop down arrow.
i.e. if the question was in row 1 and 'No' was answered a question would then appear. " wrote: Hi Assuming your Yes/No is a form button, then in the attached macro you would put Range("B1").EntireRow.Visible = True regards Paul chris wrote: Hi Is it possible to unhide a row based on the value of a cell? I am creating a questionnaire and would like to unhide a question if a certain answer is given. For example: Cell A1 - 'Question: Do you have a criminal record? Yes/No' If answer is Yes then a further question appears in B1 - 'Please provide details'. If answer was no then this will not appear. |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Then Bobbo's sub is the way to go
Paul chris wrote: Paul - I was just planning on using a drop down arrow. i.e. if the question was in row 1 and 'No' was answered a question would then appear. " wrote: Hi Assuming your Yes/No is a form button, then in the attached macro you would put Range("B1").EntireRow.Visible = True regards Paul chris wrote: Hi Is it possible to unhide a row based on the value of a cell? I am creating a questionnaire and would like to unhide a question if a certain answer is given. For example: Cell A1 - 'Question: Do you have a criminal record? Yes/No' If answer is Yes then a further question appears in B1 - 'Please provide details'. If answer was no then this will not appear. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Hide or unhide sheets based on cell | Excel Discussion (Misc queries) | |||
Hide or Unhide certain columns based on a cell value | Excel Programming | |||
Hide or Unhide Column Based on Cell Value | Excel Programming | |||
Hide/Unhide column based on cell value | Excel Programming | |||
Unhide sheets based on a cell value | Excel Programming |