ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Paste cells without tabs (https://www.excelbanter.com/excel-discussion-misc-queries/170695-paste-cells-without-tabs.html)

hmm

Paste cells without tabs
 
I want to copy the contents of two horizotally adjacent cells, and paste the
contents to rename a file in Windows Explorer. However, the clipboard
retains a tab character between the text in the cells.

How can I copy and paste the cells as run-on text, without a tab character
in between? (I want to avoid, if possible, creating a third column to
concatenate the two cells.)

joel

Paste cells without tabs
 
Because you are only copying two cells I would copy them one at a time. I
would then replace the tab with a space while copying

a = Range("A1")
b = Replace(a, Chr(9), " ")
'put b into window Explorer
a = Range("B1")
b = Replace(a, Chr(9), " ")
'put b into window Explorer


"hmm" wrote:

I want to copy the contents of two horizotally adjacent cells, and paste the
contents to rename a file in Windows Explorer. However, the clipboard
retains a tab character between the text in the cells.

How can I copy and paste the cells as run-on text, without a tab character
in between? (I want to avoid, if possible, creating a third column to
concatenate the two cells.)



All times are GMT +1. The time now is 09:47 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com