Why do I have Quotes now?

DChambers

Active Member
Joined
May 19, 2006
Messages
257
Can anyone tell me why this code does not have quotes around it when I copy and paste AF12.Value to word.

Code:
            Range("AF12").Value = "            Price: " & Format(Cells(.Row, 15).Value, "$##,##0.00##") & " each"
and this one does?
Code:
            Range("AF12").Value = "            Price: " & vbTab & Format(Cells(.Row, 15).Value, "$##,##0.00##") & " each"
The only difference is the vbTab..
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off

Norie

Well-known Member
Joined
Apr 28, 2004
Messages
76,358
Office Version
  1. 365
Platform
  1. Windows
Darrell

How exactly are you doing the copy/paste?
 
Upvote 0

DChambers

Active Member
Joined
May 19, 2006
Messages
257
After this has run I just paste it into word.
Code:
            'Range("AF12").Value = "            Price: " & Format(Cells(.Row, 15).Value, "$##,##0.00##") & " each"
            Range("AF12").Value = "            Price: " & vbTab & Format(Cells(.Row, 15).Value, "$##,##0.00##") & " each"
            Range("AF13").Value = "              MOQ: " & vbTab & Cells(.Row, 17).Value
            Columns("AF:AF").EntireColumn.AutoFit
            Range("AF2:AF13").Select
            Selection.Copy
 
Upvote 0

Norie

Well-known Member
Joined
Apr 28, 2004
Messages
76,358
Office Version
  1. 365
Platform
  1. Windows
Darrell

Perhaps I'm missing something but I don't see anything in that code that involves Word.:)
 
Upvote 0

DChambers

Active Member
Joined
May 19, 2006
Messages
257
After the:
Code:
Range("AF2:AF13").Select 
Selection.Copy
Those cells are copied into the clipboard and I just maximize word and edit, paste it right in - or did I misunderstand the question?
 
Upvote 0

Forum statistics

Threads
1,190,859
Messages
5,983,264
Members
439,833
Latest member
CDaviess

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
Top