Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 347
Default Hiding Rows if a Field Value is set to 0%

Hello,
I have a worksheet with some rows that are only applicable if the percentage
value in another field is greater than 0%. Otherwise, I want those rows to be
hidden.
Can anyone help me figure out how to do this?

Thanks very much!
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Hiding Rows if a Field Value is set to 0%

Use Autofilter on the column that contains the percentage - choose
Custom, then Not Equal To, then 0 (zero).

Hope this helps.

Pete

On Sep 1, 8:58*pm, George wrote:
Hello,
I have a worksheet with some rows that are only applicable if the percentage
value in another field is greater than 0%. Otherwise, I want those rows to be
hidden.
Can anyone help me figure out how to do this?

Thanks very much!


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 347
Default Hiding Rows if a Field Value is set to 0%

Thanks but I don't think that will work for me.
I have a field (D1) where the user can enter a percentage.
That value drives formulas on 16 other fields (4Rx4C) which are always 0 if
the field value is 0% (the default value). Therefore, they should remain
hidden.
BUT, if the user enters anything other than 0%, I want 16 other fields to
appear.

"Pete_UK" wrote:

Use Autofilter on the column that contains the percentage - choose
Custom, then Not Equal To, then 0 (zero).

Hope this helps.

Pete

On Sep 1, 8:58 pm, George wrote:
Hello,
I have a worksheet with some rows that are only applicable if the percentage
value in another field is greater than 0%. Otherwise, I want those rows to be
hidden.
Can anyone help me figure out how to do this?

Thanks very much!



  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Hiding Rows if a Field Value is set to 0%

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count 1 Then Exit Sub
If Intersect(Target, Me.Range("D1")) Is Nothing Then Exit Sub
On Error GoTo CleanUp
Application.EnableEvents = False
With Target
If .Value = 0 Then
Rows("6:9").Hidden = True
Else
Rows("6:9").Hidden = False
End If
End With
CleanUp:
Application.EnableEvents = True
End Sub


Gord Dibben MS Excel MVP

On Mon, 1 Sep 2008 13:39:02 -0700, George
wrote:

Thanks but I don't think that will work for me.
I have a field (D1) where the user can enter a percentage.
That value drives formulas on 16 other fields (4Rx4C) which are always 0 if
the field value is 0% (the default value). Therefore, they should remain
hidden.
BUT, if the user enters anything other than 0%, I want 16 other fields to
appear.

"Pete_UK" wrote:

Use Autofilter on the column that contains the percentage - choose
Custom, then Not Equal To, then 0 (zero).

Hope this helps.

Pete

On Sep 1, 8:58 pm, George wrote:
Hello,
I have a worksheet with some rows that are only applicable if the percentage
value in another field is greater than 0%. Otherwise, I want those rows to be
hidden.
Can anyone help me figure out how to do this?

Thanks very much!




  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 347
Default Hiding Rows if a Field Value is set to 0%

Thanks! That did it.

"Gord Dibben" wrote:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count 1 Then Exit Sub
If Intersect(Target, Me.Range("D1")) Is Nothing Then Exit Sub
On Error GoTo CleanUp
Application.EnableEvents = False
With Target
If .Value = 0 Then
Rows("6:9").Hidden = True
Else
Rows("6:9").Hidden = False
End If
End With
CleanUp:
Application.EnableEvents = True
End Sub


Gord Dibben MS Excel MVP

On Mon, 1 Sep 2008 13:39:02 -0700, George
wrote:

Thanks but I don't think that will work for me.
I have a field (D1) where the user can enter a percentage.
That value drives formulas on 16 other fields (4Rx4C) which are always 0 if
the field value is 0% (the default value). Therefore, they should remain
hidden.
BUT, if the user enters anything other than 0%, I want 16 other fields to
appear.

"Pete_UK" wrote:

Use Autofilter on the column that contains the percentage - choose
Custom, then Not Equal To, then 0 (zero).

Hope this helps.

Pete

On Sep 1, 8:58 pm, George wrote:
Hello,
I have a worksheet with some rows that are only applicable if the percentage
value in another field is greater than 0%. Otherwise, I want those rows to be
hidden.
Can anyone help me figure out how to do this?

Thanks very much!




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
Color alternate rows when after hiding selected rows Monk[_2_] Excel Worksheet Functions 6 June 7th 08 01:36 AM
Hiding Specific Rows Based on Values in Other Rows Chris Excel Worksheet Functions 1 November 2nd 06 08:21 PM
Hiding a button when hiding rows fergusor Excel Discussion (Misc queries) 2 August 10th 06 02:31 PM
Q: Hiding a field button on a pivot chart Kompu Kid Excel Discussion (Misc queries) 2 October 4th 05 12:43 AM
Pivot Charts, hiding field values in second level filters? elrao Charts and Charting in Excel 1 June 17th 05 10:19 AM


All times are GMT +1. The time now is 06:25 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"