RETURNING ONLY FILLED CELLS (with value/text) From sheet

Dmrs92

New Member
Joined
Jun 1, 2018
Messages
31
Hello,
I would like to have option to return cells with value/text in other sheet to another.
So if I have value in range for example from A2 to a15 in sheet1, I would like to return all values/texts without gaps to range a2 to a15 to diffrent sheet. The best option it would be makro but i can't do it. If formula can do it I take it.

Anybody can help with this issue ?

Thank you in advance,
 

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
Maybe...

Code:
Sub cpaste()
Sheets("Sheet1").Range("A2:A15").SpecialCells(2, 23).Copy Sheets("Sheet2").Range("A2")
End Sub
 
Upvote 0
It's working last question how to paste only values without source formatting ?

Code:
Sub cpaste2()
    Sheets("Sheet1").Range("A2:A15").SpecialCells(2, 23).Copy
    Sheets("Sheet2").Range("A2").PasteSpecial xlValues
    Application.CutCopyMode = False
End Sub
 
Upvote 0

Forum statistics

Threads
1,223,248
Messages
6,171,027
Members
452,374
Latest member
keccles

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top