Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Recorded replacement doesn't work

From our ERP-system I can export information to clip board, which can be
pasted to Excel. Unfortunately, the numbers has thousand separation (129
123.00)so Excel think it is text. I can replace the sign for that, Chr(160)
with a blank, and that work good. The format of the cells is numbers and I
can calculate with it in Excel. But when I tries to record this keystroke and
then replay it, it doesn't work. Excel deletes the thousand separator but
the numbers has leading blanks and the cell format is general. The macro
works good in Excel 2000 but not in 2002 and 2003. In 2002 (I think) there
was an enhancement in excel, that display a little green mark in the upper
left corner of the cell if Excel think there is an error. These cells is
marked with this, and if I place the cursor in one of these cells, this
message appears: "The number in this cell is formatted as text or has a
leading apostrophe". When I select "Convert to number", the result is
correct. But how to achieve that with hundreds of cells? I can write a macro
that does the formatting cell by cell, but it take to long time to fix all
cells. The macro line "Cells.Replace What:=Chr(160), Replacement:="",
LookAt:=xlPart" do it correct for all cells rapidly, but not when I create an
icon in the menu bar, that run the macro.
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
recorded macros Jemma Excel Worksheet Functions 3 December 10th 08 10:54 AM
Recorded macro Gaurav[_3_] Excel Discussion (Misc queries) 4 September 22nd 08 06:46 PM
I recorded a macro "PrintSetUp" in excel but does not work Niranjan Excel Worksheet Functions 1 August 10th 07 02:57 PM
How to FIX Recorded Macro JMay Excel Discussion (Misc queries) 7 May 23rd 07 04:13 AM
Recorded Macro want to know New Users to Excel 5 February 14th 07 12:46 PM


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

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

About Us

"It's about Microsoft Excel"