Pulling Multiple Vales From Multiple Cells & Displaying them in one cell.

J

JPP

I have 100 cells that display either a number, or nothing in them. I
there is a number >=1, I would like it to display on one page, my maste
page. The second page is where I copy & paste all of my information, an
the display page, or pretty part is the first page. I have tried man
thing I have seen, the + method, the &""& method. None of these work. I
it possible to display the content all in one cell
 
G

Gord Dibben

Sub Combine_Numbers()
Dim lastrow As Long
Dim cell As Range
Dim DataRng As Range
Dim strRow As String
lastrow = Cells(Rows.Count, "A").End(xlUp).Row
Set DataRng = ActiveSheet.Range("A1:A" & lastrow)
For Each cell In DataRng
If IsNumeric(cell.Value) And cell.Value >= 1 Then
strRow = strRow & cell.Value & ","
End If
Next cell
Sheets("Master").Range("B1").Value = strRow
End Sub


Gord
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top