+ Reply to Thread
Results 1 to 4 of 4

Search for Partial Text

  1. #1
    Forum Contributor
    Join Date
    02-12-2011
    Location
    Hyderabad
    MS-Off Ver
    Excel 2016
    Posts
    270

    Search for Partial Text

    Hello All

    I am trying to write a code for searching for partial text in a cell when user enters value through an input box function.
    For example Cell A10 has a value for post code cell B10 should show the respective country as below

    CELL A10 : AB1 CD2
    CELL B10: USA

    CELL A10 : UK1 EF2
    CELL B10: UK

    CELL A10 : IN1 GF2
    CELL B10: INDIA


    So if cell A10 has value starting with AB/UK/IN it should show the respective country . no matter what the other part of the text is.
    can we do this through search/find/match options on VB . How to write a code for this and whats the best way do it



    Thanks for u r time
    Last edited by grkchakri; 02-18-2012 at 04:55 AM. Reason: Incorrect format

  2. #2
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Search for Partial Text

    To find Text Starting with AB use the below code.

    Please Login or Register  to view this content.

  3. #3
    Forum Contributor
    Join Date
    02-12-2011
    Location
    Hyderabad
    MS-Off Ver
    Excel 2016
    Posts
    270

    Re: Search for Partial Text

    But how will that give the value in b10

  4. #4
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Search for Partial Text

    To get B column value add this code after that.

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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