LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Conditional popup

I am putting together a spreadsheet that allows a client to enter
ineterview criteria that is weighted etc. Part of this is allowing them
to change the weights (pervcentages). I would like for a popup message
to appear if the percentage goes over 100.

I have roughly put this together

Function ValueCheck(ByVal Target As Range, Maximum As Integer)
If Sum(Target.Column) Maximum Then
Beep
MsgBox "Caution, 100% has been exceeded!"
End If
End Function

In the cell that shows total percentage I have =ValueCheck(B7:B28,100)

I would like to try make it pretty generic so I can check against other
values later.

As a 2nd, how can I out a variable in the msgBox message ie: instead of
100% just put Maximum.

TIA

W
 
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
Picture popup TheSAguy Excel Discussion (Misc queries) 2 May 28th 08 06:17 PM
A popup to filter out what you don't need. simplymidori[_2_] Excel Discussion (Misc queries) 3 July 27th 07 04:27 PM
Popup MsgBox jackle Excel Discussion (Misc queries) 1 February 13th 06 03:44 AM
"Why did we get here????" popup jtwspoon Excel Discussion (Misc queries) 3 February 4th 05 04:57 AM
Are you sure popup box Todd Huttenstine[_2_] Excel Programming 2 November 9th 03 09:38 PM


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