Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Mr. G.
 
Posts: n/a
Default Unhiding multiple rows simutaneously

I have the following (view code) macro that unhides/hides rows (one at a
time) in 2 worksheets depending on the User populating a certain range of
cells:

If Not Intersect(Target, Me.Range("F11:F14")) Is Nothing Then
On Error Resume Next
Application.ScreenUpdating = False
Application.Calculation = xlCalculationAutomatic

For Each c In Range("F12:F14")
If c.Value = "" And c.Offset(0, 45) = 0 Then
Sheets("WKLY-RPT").Unprotect ("lindAP")
Sheets("EXP RPT").Unprotect ("lindAP")
c.EntireRow.Hidden = True
i = c.Row
Sheets("WKLY-RPT").Rows(i).EntireRow.Hidden = True
Sheets("WKLY-RPT").Protect ("lindAP")
Sheets("EXP RPT").Protect ("lindAP")
End If
Next
For Each c In Range("F11:F14")
If c.Value < "" Then
Sheets("WKLY-RPT").Unprotect ("lindAP")
Sheets("EXP RPT").Unprotect ("lindAP")
c.Offset(1, 0).EntireRow.Hidden = False
i = c.Row
Sheets("WKLY-RPT").Rows(i + 1).EntireRow.Hidden = False
Sheets("WKLY-RPT").Protect ("lindAP")
Sheets("EXP RPT").Protect ("lindAP")
End If
Next
End If
Application.ScreenUpdating = True
Application.Calculation = xlCalculationAutomatic
End Sub

Now, is it possible to incorporate another similar function that would also
unhide/hide rows 102:105? If it helps, I've set-up rows 102:105 ("EXP RPT)
to correspond with cells F11:F14, whereby a numeral "1" is automatically
inserted into cells D102:D105" when cells F11:F14 are populated.

Hope I didn't confuse anybody.
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
Unhiding rows using data validation Mr. G. Excel Worksheet Functions 0 April 7th 05 06:37 PM
Deleting multiple rows through a formula mike_vr Excel Discussion (Misc queries) 1 March 15th 05 01:29 PM
Multiple rows of data on a single axis (charting) ramseysgirl Charts and Charting in Excel 8 December 29th 04 06:00 PM
Inserting Multiple Rows with Formulas ShineboxNJ Excel Worksheet Functions 2 November 18th 04 02:30 AM
Count rows based on multiple criteria Murph Excel Worksheet Functions 1 October 28th 04 07:13 AM


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