LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #7   Report Post  
Posted to microsoft.public.excel.misc
Tel Tel is offline
external usenet poster
 
Posts: 39
Default Macro adjustment

Thanks guys,

I've ticked all the boxes for all of you.

Just a point to others, when using this solution make sure your numbers are
true numbers and not stored as Text - It did my bleeding 'ead in until I
realised the error of my ways. (make sure you don't have " " around your
numbers :-))

Tel

"Tel" wrote:

Hello,

I have a macro that cuts and pastes as values the contents of cells E3 to
E45 of (Sheet2) to another, hidden, worksheet (sheet6) then unhides and
selects cell C3 of Sheet3.

However, if the values of E3 to E45 ALL equal either "0" or " " then I'd
like to to keep Sheet3 hidden and move on to Sheet 4. But if the value of
even one of the cells from E3 to E45 equals "1", "2", or "3" then I need to
unhide sheet3 and select cell C3 ready for input.

To prove I'm not a complete numpty and I'm learning from you guys, I'm
guessing there's an If and else in there somewhere and that it goes something
like....

If value.Range("E3:E45") = 0 Then
Sheets("Sheet4).Select
Range("C3").Select
Else
Sheets("Sheet3").Visible = True

Sheets("Sheet3").Select
Range("C3").Select
End If

Application.ScreenUpdating = False

End Sub

I tried it but it throws a big red hissy fit at me :-)

Your help is much appreciated.

Regards,

Tel

 
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
Sumproduct Adjustment Ellen G Excel Discussion (Misc queries) 4 November 29th 07 09:14 PM
formula adjustment Candace Excel Worksheet Functions 2 November 3rd 07 10:02 PM
automatic adjustment daidipya Excel Discussion (Misc queries) 1 June 8th 06 02:46 PM
Event Macro adjustment needed - need to change font color also nick s Excel Worksheet Functions 2 November 28th 05 05:50 PM
Copy without Adjustment Gary's Student Excel Discussion (Misc queries) 5 May 1st 05 11:04 PM


All times are GMT +1. The time now is 12:35 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"