+ Reply to Thread
Results 1 to 3 of 3

"201" and 201

  1. #1
    Forum Contributor
    Join Date
    11-21-2013
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    190

    "201" and 201

    Hi, I used below code, but it didn't work.
    When I look the Immediate window, it says, ?ws.Range("S" & i) = wsN.Range("A" & r) = False
    The Column S in ws and Column A in wsN are 'General' format.
    The column S has 201, 302, 401, 502,,, and so on.
    The column A in wsN has 202, 201, 401,,, and so on.
    The immediate window says "201" and 201, even if it has the same 201.
    I think this cause the problem.
    How can I solve this?
    Thanks

    Please Login or Register  to view this content.

  2. #2
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: "201" and 201

    Change either of them in to string or value

    If CStr(ws.Range("S" & i)) = wsN.Range("A" & r) Then

    OR

    If ws.Range("S" & i) = Val(wsN.Range("A" & r)) Then

  3. #3
    Forum Contributor
    Join Date
    11-21-2013
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    190

    Re: "201" and 201

    Thanks! It works.

+ 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: 1
    Last Post: 01-22-2016, 09:21 AM
  2. Replies: 1
    Last Post: 08-15-2014, 06:00 AM
  3. Replies: 4
    Last Post: 11-17-2013, 12:05 PM
  4. [SOLVED] How to USE """"" cells count """"" change font color
    By austin123456 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 10-09-2013, 06:14 AM
  5. Replies: 5
    Last Post: 10-12-2010, 06:46 AM
  6. Replies: 5
    Last Post: 06-26-2006, 09:23 PM
  7. Replies: 7
    Last Post: 05-13-2006, 05:02 PM

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