+ Reply to Thread
Results 1 to 4 of 4

Search for character, return part of string in another cell

  1. #1
    Registered User
    Join Date
    08-08-2014
    Location
    sweden
    MS-Off Ver
    2010
    Posts
    4

    Search for character, return part of string in another cell

    Hi!

    I have some problem to find a solution to my problem, I have tested a few things but I dont get it to work. I want to search for character * in column C, any row between 6-8, if the function finds the character, I want it to return the five-digit number in column A. The table repeats itself every tenth row.

    A B C D E F
    1 *N. 40875 - 3/17/2015 9:28:28 PM*
    2 *Cykeltid 17.9 sek.*
    3 DETALJ GODK.
    4
    5 Mätn.n Mätfinger Init. Def's Slutl. Def's Initial RUNOUT Slutlig RUNOUT
    6 1 0,1,7 116* 79 167 102
    7 2 0,2,7 180* 54 211* 68
    8 6 0,3,7 157* 2 191 58
    9
    10

  2. #2
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,914

    Re: Search for character, return part of string in another cell

    pls attach sample excel file with expected result instead of Image
    Samba

    Say thanks to those who have helped you by clicking Add Reputation star.

  3. #3
    Registered User
    Join Date
    08-08-2014
    Location
    sweden
    MS-Off Ver
    2010
    Posts
    4

    Re: Search for character, return part of string in another cell

    test.xlsx

    Hi, i just entered the value that I want as result from the function, so basically I want the function to check if each item have any star in the cells under the "Init.Def's" and if it's true, it shall then list the item number in "Result". Its not always a star in all the three rows under "Init.Def", so I want the function to check all of the three rows.

  4. #4
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,914

    Re: Search for character, return part of string in another cell

    =IFERROR(IF(SUMPRODUCT(LEN(C7:C9)*1)-SUMPRODUCT(LEN(SUBSTITUTE(C7:C9,"*",""))*1),MID(A2,5,5),"")+0,"")
    Try this one
    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)

Similar Threads

  1. Script to Search for a specific String then return cell values above that String-4
    By owensjb2 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-03-2015, 01:28 AM
  2. [SOLVED] Script to Search for a specific String then return cell values above that String-3
    By owensjb2 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-01-2015, 01:50 PM
  3. [SOLVED] Script to Search for a specific String then return cell values above that String-2
    By owensjb2 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-01-2015, 01:00 PM
  4. [SOLVED] Script to Search for a specific String then return cell values above that String
    By owensjb2 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-01-2015, 11:28 AM
  5. [SOLVED] search for a "part number" within a string and return its cell position or contents of cel
    By benakil in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-24-2013, 06:37 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