Help!

Adding Quotation Marks to Data already in Mulitple Cells

 
Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> Setup RSS
Next:  Display page breaks automatically  
Author Message
Ron
External


Since: Jun 16, 2004
Posts: 297



PostPosted: Thu Feb 22, 2007 1:05 pm    Post subject: Adding Quotation Marks to Data already in Mulitple Cells
Archived from groups: microsoft>public>excel>setup (more info?)

How can I add quotation marks around content within multiple cells in an
excel spreadsheet without doing it manually in Office 2002? For example, If
there is data in Cells A1 through A100 and I want quotations marks around
the data in each cell is there a way to add the quotation marks in each cell
without losing the data? The data is both numeric and text.
Back to top
Gary''s Student
External


Since: Oct 01, 2005
Posts: 3403



PostPosted: Thu Feb 22, 2007 1:54 pm    Post subject: RE: Adding Quotation Marks to Data already in Mulitple Cells [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Select the cells you want to modify and run:

Sub dont_quote_me()
q = Chr(34)
For Each r In Selection
r.Value = q & r.Value & q
Next
End Sub

--
Gary''s Student
gsnu200707


"Ron" wrote:

> How can I add quotation marks around content within multiple cells in an
> excel spreadsheet without doing it manually in Office 2002? For example, If
> there is data in Cells A1 through A100 and I want quotations marks around
> the data in each cell is there a way to add the quotation marks in each cell
> without losing the data? The data is both numeric and text.
Back to top
Ron
External


Since: Jun 16, 2004
Posts: 297



PostPosted: Fri Feb 23, 2007 1:36 pm    Post subject: RE: Adding Quotation Marks to Data already in Mulitple Cells [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Gary,
I take that this is a vbs script? If so then how do I get it to run in
the excel spreadsheet that I'm trying to add the quotation marks to?

"Gary''s Student" wrote:

> Select the cells you want to modify and run:
>
> Sub dont_quote_me()
> q = Chr(34)
> For Each r In Selection
> r.Value = q & r.Value & q
> Next
> End Sub
>
> --
> Gary''s Student
> gsnu200707
>
>
> "Ron" wrote:
>
> > How can I add quotation marks around content within multiple cells in an
> > excel spreadsheet without doing it manually in Office 2002? For example, If
> > there is data in Cells A1 through A100 and I want quotations marks around
> > the data in each cell is there a way to add the quotation marks in each cell
> > without losing the data? The data is both numeric and text.
Back to top
Gary''s Student
External


Since: Oct 01, 2005
Posts: 3403



PostPosted: Fri Feb 23, 2007 3:15 pm    Post subject: RE: Adding Quotation Marks to Data already in Mulitple Cells [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Very easy:

1. touch ALT-F11 to bring up the VBE window
2. touch ALT-I
ALT-M to insert a fresh module
3. paste the stuff into the module
4. close the VBE window (save is not necessary)


to run the script

1. select the set of cells you want to process
2. touch ALT-F8
3. select the macro
4. touch run

--
Gary's Student
gsnu200707


"Ron" wrote:

> Gary,
> I take that this is a vbs script? If so then how do I get it to run in
> the excel spreadsheet that I'm trying to add the quotation marks to?
>
> "Gary''s Student" wrote:
>
> > Select the cells you want to modify and run:
> >
> > Sub dont_quote_me()
> > q = Chr(34)
> > For Each r In Selection
> > r.Value = q & r.Value & q
> > Next
> > End Sub
> >
> > --
> > Gary''s Student
> > gsnu200707
> >
> >
> > "Ron" wrote:
> >
> > > How can I add quotation marks around content within multiple cells in an
> > > excel spreadsheet without doing it manually in Office 2002? For example, If
> > > there is data in Cells A1 through A100 and I want quotations marks around
> > > the data in each cell is there a way to add the quotation marks in each cell
> > > without losing the data? The data is both numeric and text.
Back to top
Display posts from previous:   
Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> Setup All times are: Eastern Time (US & Canada)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum