Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Work with cell contents?

Is it possible within Excel to create a macro to manipulate the
contents of each cell in a column.

The sort of tasks I wish to do include:

(a) Remove spaces. [i.e. "ca ts 5" becomes "cats5"]
(b) Insert character at a certain position [i.e. "12345" becomes
"123-45"]

Thank you

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default Work with cell contents?

Hi,

Doing those things is relatively simple by either using a macro or a
worksheet function and I'm sure if you can give a more specific example of
what you want then help will be forthcoming.

Mike

" wrote:

Is it possible within Excel to create a macro to manipulate the
contents of each cell in a column.

The sort of tasks I wish to do include:

(a) Remove spaces. [i.e. "ca ts 5" becomes "cats5"]
(b) Insert character at a certain position [i.e. "12345" becomes
"123-45"]

Thank you


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,856
Default Work with cell contents?

You can do those two things without a macro.

For the first one, highlight the cells that you want to do this to,
then Edit | Replace (or CTRL-H) and enter:

Find what: <space
Replace with: leave blank

Then click Replace All.

For the second one you can use a custom format if the numbers are
proper numbers, otherwise you can use a formula with LEFT and RIGHT
functions to insert the hyphen.

Hope this helps.

Pete

On Aug 18, 6:39 am, wrote:
Is it possible within Excel to create a macro to manipulate the
contents of each cell in a column.

The sort of tasks I wish to do include:

(a) Remove spaces. [i.e. "ca ts 5" becomes "cats5"]
(b) Insert character at a certain position [i.e. "12345" becomes
"123-45"]

Thank you



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Very Basic Problem - Merged Cell Equals Contents of a Single Cell jollynicechap Excel Worksheet Functions 3 December 29th 06 08:16 PM
Autofit didn't work to adjust row height to fit wrapped contents nwacct Excel Discussion (Misc queries) 4 May 31st 06 10:13 PM
Macro to remove contents of cell and move all other contents up one row adw223 Excel Discussion (Misc queries) 1 July 1st 05 03:57 PM
Cell contents vs. Formula contents Sarah Excel Discussion (Misc queries) 3 December 15th 04 06:02 PM
How can I create a table of contents(worksheets) for a large work. brupub Excel Discussion (Misc queries) 7 December 5th 04 05:16 PM


All times are GMT +1. The time now is 04:59 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"