![]() |
Msgbox and variants - a deadly combination
Dear
I am attempting to show cells A1 to B4 in a msgbox. The code I had tried is: dim c1(6) as integer dim c5 as variant c1(6) = Selection.CurrentRegion.Rows.Count c5 = (Range("A1:B" & (c1(6)))) MsgBox c5 However, this is not working. Any ideas? Thanks, Peter |
Msgbox and variants - a deadly combination
Thanks for that.
Only one problem, that creates a msgbox for each cell. Is there any way to have all the information in one msgbox? Peter On 24 Jan, 14:28, Gary''s Student wrote: Sub peter() Set r = Range("A1:B4") For Each rr In r MsgBox (rr.Value) Next End Sub This will show cells A1 to B4 in a messagebox -- Gary''s Student gsnu200702 "Peter" wrote: Dear I am attempting to show cells A1 to B4 in a msgbox. The code I had tried is: dim c1(6) as integer dim c5 as variant c1(6) = Selection.CurrentRegion.Rows.Count c5 = (Range("A1:B" & (c1(6)))) MsgBox c5 However, this is not working. Any ideas? Thanks, Peter- Hide quoted text -- Show quoted text - |
All times are GMT +1. The time now is 11:14 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com