If I have a store number (say 1234) and I am trying to search for something which contains 1234 (i.e. the whole string of ABCD1234, ABCD1235, ABCD1236 etc) is it possible to do this in one VLOOKUP formula?
One way of doing it would be to VLOOKUP("ABCD"&"1234",....) but I would rather do it the other way around, to prevent the formula from not working.
What I want to do is sum all the values after the / for a particalur value before the /:
A 8 B 4
I already tried VLOOKUP, but this function wants you to point to a certain cell to return instead of a just a part of the cell. It should return 5 for the first row to be able to perform a sum for every value of A.
How can I perform such a calculation without having to copy the values to separate cells? Can I contain all of this in one function?
Im sure this cant be done because it defies the logic of the LOOKUP function but I know there are some clever people on here so i thought id ask!!
I have 2 workbooks containing similar data from 2 different sources; the one common data item in both is a clients address but have the age old problem of data quality, which needs sorting eventually but i need a quick fix!
In workbook one for example the address will be recorded as RUSKIN RD
In workbook two the address will be recorded as RUSKIN ROAD
A simple look up wont work obviously as the 2 values dont match, then i thought of using the LEFT function but again this goes against the logic of the VLOOKUP.
Is there any way I can Vlookup for just part of a text stiring in a cell. I am trying to vlook if a part number contains the letters “HFR” if it does I want It to refer to the comment I have made in the second column of my vlook table against HFR.
I am trying to reference a Name of a place from an order number. To illustrate, University Park, IL can have an order # of 6598641373. The only thing is, all I need to reference is the first four digits, 6598. The other worksheet does not have city and state names, they only have the order #s.
Also I have a Userform with 2 ComboBoxes named "ComboBox1" and "ComboBox2". Values in ComboBox1 is "Pull my pants", "Eat my shorts", "Socks for everyone".
What I would like to do is to search though column A and look for any of these textstrings in my selection in ComboBox1 and return the value from column B in column C.
Example: "Pull my pants" is selected in ComboBox1 then the value "pants" should be found in column A and value in column B (25) should be entered in cell C2.
I am fairly new to VBA and have spend hours searching Google and found some formulas like InStr and VLookup. My problem is that I am not sure if these statements will do the job and how to combine them.
This formula works correctly, displaying the lookup value for K7. My query is between the"" I can place text to display when K7 is blank and this works correctly too. However I would like to place a formula in here. The formula is VLOOKUP(I7,Orig!A7:B35,COLUMNS(B7:B35)+1,0 i.e. the lookup value is now I7 and not K7 when K7 is blank.
I have tried the following and variations based on what I know but they return errors.
Is there any way to remove the first part of a string of text in a cell and save the second part?
The first part of the text string is a team code that has a variable number of numbers, capital letters and sometimes spaces. The second part of the text string is a variable number of words in a team name that all start with a capital letter and have lower case letters. Every line has a different team code and team name.
The original spreadsheet also has a column with just team code. Is there a way of using this column to "subtract" the team code from the text string to just leave the team name?
I have a Vlookup which I want to modify so that it can become dynamic as the table array part of the vlookup will change.
So the basic vlookup is as follows: =VLOOKUP($R$3,ATTRIBUTION_FACTSET!$M$60:$P$73,2,0) but the data I am looking for wont always be in the range M60:P73.
So I tried to make it dynamic by doing the following: =VLOOKUP($R$3,INDIRECT("ATTRIBUTION_FACTSET"&"!M"&U1&":P"&V1),2,FALSE) The idea being that U1 and V1 would be numbers that can change so in this case U1 would equal 60 and V1 would equal 73
This vlookup is giving me #N/A and no matter how I modify it I cannot get it to work.
all the rows of data get a unique file number , no duplicates.
the file number format is 1.01, or 241.00, or 5132.03,etc.
all numbers to the left of the period symbol are "file info" reference all numbers to the right of the period symbol are "bills" found inside the file #. there can be any amount of file #'s, always starting from 1 thru as many as there can be (apprx. thousands of files). and the bills can be from .00 thru .99
my search field ($r$9), need to search or find only the exact match to the left of the period.
NEED to search for file 1, i need the array table to kick back only the file numbers 1.01 and 1.65, not 241.00 not 3.01.
how can i search only the text before the period to the left and exactly what is entered into my search box?
I have a spreadsheet which has "Employee: [agent 1 name]" in column A and it may or may not have the word "Break" in the same column before it mentions "Employee: [agent 2 name]". The amount of data between agent 1 and agent 2 varies and am needing code which will insert a row above "Employee: [agent 2 name]" if "Break" is not found, and add the word "Break" in column A on the inserted row. I would need this to loop through the spreadsheet until all 100+ agents have been searched.
I'm also needing this done for the word "Meeting" and would insert a row 2 rows above the next agent.
formula that will pull out the number preceding the * 60 in the text below? In this particular case I would be looking to get 5 as the result. That number could be any number but in the example below it happens to be a 5.
Channel Tune Duration in Seconds} (ID) >= (5 * 60))
I have a list of data that populates B2:B2900 This data is often prefixed by a 'reference code' that I wish to be removed. Now rater than perform this manually aprox 3000 times is there a formula or some VB code that will complete this for me....
The list of data is shown like:
SC7547-05 - Payne, Freda SC8706-08 - Rungren, Todd SC8714-05 - Travis, Randy SC7517-03 - Beach Boys, The Love Song Now You're Gone SC7512-01 - Horton, Johnny SC8721-15 - Journey
So I wish for the SC7547-05 - to be removed from the first example to just leave Payne, Freda and continue this throughout the list However if the data is found not to include this code (as in the 5th/6th examples above) leave it alone
So if the code of formula is run for the above the outcome would be....
Payne, Freda Rungren, Todd Travis, Randy Beach Boys, The Love Song Now You're Gone Horton, Johnny Journey
I need to take out the number in the middle, from the period to the space. The number varies in length so just using the mid function doesn't work. Does anyone know how to modify the mid function to return all chars between the period and the space or is there some other function that may work?
I have a work problem where my spreadsheets have the following structure due to faulty optical character recognition:
Ringholm 8 G R hem.ag Bavik Postl 115 O Amtervik Rinman K H B dir Johannebergsg 34 Goteborg S Risberg L kass Mitandersfors Bogen
In some cases the letters in the beginning of the cells have been misread as a number (above S as 8), so I want to search and replace those numbers with the correct letter without changing the correct numbers at the end of the cells to letters too. Is there any way to write a search-and-replace code in VBA that will only implement the search-and-replace in (for example) the first five letter-spaces of the cell?
What i have so far is: -3 Sheets (Sheet1 - Search, Sheet2 - Data, Sheet3 - Result) -Sheet1 has a userform ready to link up - this opens up when workbook and worksheet is activated. -Sheet2 has some example data to search - the search is for column 1 (see attachment) -Sheet3 has a template ready for the data to be pasted to.
I would like the search result is column 1 to copy the data from columns 1 to 7 to sheet3.
I want the template/layout to remain after the pasting of results. (everything protected from editing, if possible).
Once finished (ie go back to sheet1, i want the data from sheet3 to be cleared.)
I have a conditional formula which gives a value based on what the User specifies.
Example of formula is:
=IF($B$1=0,"CONTACT PERSON - OPTIONAL",IF($B$1=5,"CONTACT PERSON (FINANCE ONLY) - MANDATORY",""))
If the result of the string is " CONTACT PERSON (FINANCE ONLY) - MANDATORY " then - word MANDATORY (not the whole string) should be in RED - words (FINANCE ONLY) should be in BLUE - remaining string should be left in BLANK
I am currently working on creating a dialogue which will allow the user to input a range of worksheets to use for a pivot table.
I want the user to be able to input a variable into the dialogue. For example, I want the input "n-5 - n-1" to mean the 6th from last to the 2nd from last sheets. I am trying to find n - ([0-9]+)? and replace it with Worksheets.Count - $1. In other words, if there are 10 sheets, I want to transform "n-5 - n-1" into "5 - 9".
Here is the code I have so far:
This has been working for strings like "n" or "n-4" but not "4 - n-3" or "n-5 - n-1".
Here is the code I use afterwards to interpret the string once the n's have been replaced:
I belong to a fantasy cycling league and after every race, I copy the race results to award each rider their points for the day. The site I visit most frequently lists the riders results in this format:
1. Alberto Contador (Spa) Team Sax Bank Tinkoff 4:05:00 2. Lance Armstrong (USA) Team Livestrong etc... 4:06:00
I usually copy the results to my spreadsheet then calculate each riders points.
The'results end up looking like this in Excel:
1. Alberto Contador (Spa) Team Sax Bank Tinkoff 4:05:00 2. Lance Armstrong (USA) Team Livestrong 4:06:00
So, the data ends up in 3 cells. The position in one cell, the rider and their nationality and their team in another, and the time of arrival in another cell
Is there a way in Excel where I can get rid of or delete all the data after a rider's name?
I usually end up pasting the rider information to Word, then replacing the (***) with a tab symbol, then pasting back to Excel and get rid of the data that's after the name by deleting the cells to which that data was transferred.
Is there an easier way to do this in Excel, or a macro I can create?...
I have a worksheet that I need to filter on 8 columns. I need to do this in the form (Col A = Bob OR SAM) AND (Col B = Apple OR Pear OR Banana) AND... etc for 8 columns.
I started this thread and we reached the conclusion that I needed either a macro to list out all the possible combinations on separate lines, or a complex criteria formula.
I'm trying to put together the complex criteria, but I am further stumped by the fact that some of the columns contain multiple terms with comma delimiters, so I'm trying to match part of a string, rather than a whole string, so the usual = ISNUMBER(MATCH(Sheet1!A2,Sheet2!$A:$A,0)) won't work. I tried using =ISNUMBER(FIND(Sheet2!$A:$A,Sheet1!A2)) instead, but I think this fails because it should be an array formula. I tried normal entering and CSE entering, and neither work, so I think this is a dead end.