Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Looping Data = TRUE to a MsgBox
Could someone provide an example of Looping thru a range of 20 records
and where say 5 records = True, and 15 = False; On completion a Msgbox would Pop-up stacking the results as follows: TrueCell1.Address TrueCell1.Value << ... & Chr (10) &... is involved here (I think). TrueCell2.Address TrueCell2.Value TrueCell3.Address TrueCell3.Value TrueCell4.Address TrueCell4.Value TrueCell5.Address TrueCell5.Value Sorry not to have all required data, but any help would be appreciated. TIA, |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Looping Data = TRUE to a MsgBox
sStrTrue = " - True - " & vbNewLine
sStrFalse = " - False - " & vbNewLine for each cell in Range("A1:A20") if cell.Value then sStrTrue = sStrTrue & cell.Address & " " & cell.Value & vbNewLine else sStrFalse = sStrFalse & cell.Address & " " & cell.Value & vbNewline End if Next msgbox sStrTrue & sStrFalse if you want them spaced exactly in columns, that would take a bit more work. -- Regards Tom Ogilvy "JMay" wrote in message news:X_TId.34804$jn.25212@lakeread06... Could someone provide an example of Looping thru a range of 20 records and where say 5 records = True, and 15 = False; On completion a Msgbox would Pop-up stacking the results as follows: TrueCell1.Address TrueCell1.Value << ... & Chr (10) &... is involved here (I think). TrueCell2.Address TrueCell2.Value TrueCell3.Address TrueCell3.Value TrueCell4.Address TrueCell4.Value TrueCell5.Address TrueCell5.Value Sorry not to have all required data, but any help would be appreciated. TIA, |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Looping through data on consecutive pages | Excel Discussion (Misc queries) | |||
Function to return True/False if all are validated as True by ISNU | Excel Worksheet Functions | |||
looping through and organizing a large amount of data | Excel Programming | |||
msgbox data | Excel Programming | |||
Looping Macro to remove data where value is 0 | Excel Programming |