+ Reply to Thread
Results 1 to 2 of 2

find and replace: number format not changed by macro

  1. #1
    Registered User
    Join Date
    05-11-2015
    Location
    Hasselt, Belgium
    MS-Off Ver
    2012
    Posts
    35

    find and replace: number format not changed by macro

    Hi,

    If I manually do find "." and replace "," I see the cell change to a number format (number moves to the right)
    This is what I need. When I record this macro the number doesn't change to a number format.
    Does anyone has an idea?

    Macro I use:
    Range("F1:F12").Select
    Selection.Replace What:=".", Replacement:=",", LookAt:=xlPart, _
    SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
    ReplaceFormat:=False

    excel document: attached
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    11-24-2013
    Location
    Paris, France
    MS-Off Ver
    Excel 2003 / 2010
    Posts
    9,831

    Re: find and replace: number format not changed by macro


    Hi !

    Selection.Replace What:=".", Replacement:=".", LookAt:=xlPart, _

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 3
    Last Post: 12-01-2014, 12:15 AM
  2. Basic Find, Replace and Format change macro
    By cmphibbs in forum Excel General
    Replies: 1
    Last Post: 06-27-2013, 06:22 AM
  3. [SOLVED] Need a macro to find and replace plus change format of another colum
    By cejamgr in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 01-29-2013, 07:13 PM
  4. Replies: 0
    Last Post: 01-31-2012, 08:51 PM
  5. Replies: 0
    Last Post: 06-28-2006, 01:10 PM
  6. [SOLVED] replace one tag in content of one cell and format not changed:123#abc#456
    By replace one tag in content of one cell a in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-09-2006, 12:10 PM
  7. replace one tag in content of one cell and format not changed
    By replace one tag in content of one cell a in forum Excel General
    Replies: 1
    Last Post: 01-09-2006, 11:40 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1