Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is There A Way to Auto Add Single Quotes Around Text? 1

Status
Not open for further replies.

txdave35

Technical User
Nov 20, 2008
122
US
Hey guys,

I have an Excel spreadsheet with a column of text data. I want the text data in each cell to be surrounded by a pair of single quotes.

Is there any way to get Excel to automatically do this so I don't have to manually type in the quotes in each cell? I am running Excel 2003, and I really don't know much about VB scripting or complex formulas. Thanks!
 



Hi,
[tt]
=""""&A2&""""
[/tt]
and copy down.



Skip,
[glasses]Don't let the Diatribe...
talk you to death![tongue]

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Thanks Skip. However, this code places double quotes around my text. Is there a way to get it to place single quotes? Thanks!
 


We have QUOTES and APOSTROPHIES
[tt]
="'"&A2&"'"
[/tt]


Skip,
[glasses]Don't let the Diatribe...
talk you to death![tongue]

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 


Thanx!

Skip,
[glasses]Don't let the Diatribe...
talk you to death![tongue]

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top