+ Reply to Thread
Results 1 to 4 of 4

Using an 'OR' command in the VBA code Cells.Replace.

  1. #1
    Forum Contributor
    Join Date
    11-08-2012
    Location
    Manchester, UK
    MS-Off Ver
    Excel 2016
    Posts
    140

    Using an 'OR' command in the VBA code Cells.Replace.

    Hello,
    I am using the following code;
    Please Login or Register  to view this content.
    Is it possible to put an 'OR' in this command so I look for "time" or "_time" and replace with "Time Stamp"?
    I have tried the following but hasn't worked;
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    I'm sure I am going to kick myself when I see the answer. Thank you

  2. #2
    Registered User
    Join Date
    02-09-2014
    Location
    Fukuoka
    MS-Off Ver
    Excel 365
    Posts
    11

    Re: Using an 'OR' command in the VBA code Cells.Replace.

    Obviously, I suppose, you could first replace _time with time then time with Time Stamp ?

  3. #3
    Forum Expert dangelor's Avatar
    Join Date
    09-06-2011
    Location
    Indiana, USA
    MS-Off Ver
    365 Pro Plus
    Posts
    2,274

    Re: Using an 'OR' command in the VBA code Cells.Replace.

    Possibly...
    Please Login or Register  to view this content.

  4. #4
    Forum Contributor
    Join Date
    11-08-2012
    Location
    Manchester, UK
    MS-Off Ver
    Excel 2016
    Posts
    140

    Re: Using an 'OR' command in the VBA code Cells.Replace.

    Thanks all, now got the coding correct.

+ 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. [SOLVED] Emoji Unicode VBA replace code with icon in cells
    By asitiz in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 07-15-2018, 08:48 AM
  2. [SOLVED] Help with code for a command button that changes strikethrough cells green
    By SerraAngel in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 11-05-2014, 01:59 AM
  3. Replies: 5
    Last Post: 06-18-2014, 02:25 PM
  4. VBA Code to delimit Column A and Replace cells in Col E
    By FLani in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-27-2013, 06:44 AM
  5. replace multiple cells in a single command
    By smoptions in forum Excel General
    Replies: 0
    Last Post: 03-06-2013, 01:13 PM
  6. Command Button Code to Delete Unprotected Cells Only
    By macky1730 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-01-2011, 04:30 AM
  7. Code to replace text in a range of cells in a particular column
    By Zyphon in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 10-16-2007, 06:57 AM

Tags for this Thread

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