Removing Dash From Text Number String?

Oct 3, 2010

We often get spreadsheets from our customer that are formatted with both comma and dash combinations. We would like to only have the comma seperation.

Example:
R1, R2, R3-R5, R30

Result:
R1, R2, R3, R4, R5, R30

There is usually only one alpha character but sometimes more. Example: CR1, CR2, CR3-CR5.

The following macro works great if there are no alpha characters. how to solve the alpha/numeric combination?

Function Nums(rng As Range) As String
Dim adnum As Integer, n As Integer, num, Txt As String
num = Split(rng, ",")

[Code]....

View 9 Replies


ADVERTISEMENT

Replace Space With Dash In Text String?

Aug 7, 2013

I am looking to replace the space in between numbers and letters in a text string. The number of entries varies with each row.

Example of the entries in the column I need to reformat. Each entry is in a new row.

Code:
10 SSS
24 MNL
17 HLG 18 LTN
17 CBG 17 HLG 15 HIL 15 thn 22 ALV
17 ELP 34 HLG 15 HIL18 THN 10 TTL

What I am looking to achieve:

Code:
10-SSS
24-MNL
17-HLG 18-LTN
17-CBG 17-HLG 15-HIL 15-thn 22-ALV

17-ELP 34-HLG 15-HIL 18-THN 10-TTL

View 3 Replies View Related

Removing Dashes Deletes Everything After First Dash

Mar 25, 2013

I have entries that look like this - 300-7188258-1

300-8983980-5

I need to remove the dashes. I find and replace all - with nothing. that has worked for YEARS. Seems simple to me.

Today, when I do it, Excel leaves the "300" and removes everything else. I even did a CLEAN function and it still does it.

View 3 Replies View Related

Removing Part Of Text From A String

Feb 11, 2013

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?...

View 9 Replies View Related

Removing Text From Middle Of Text String?

Jan 31, 2012

I am trying to remove a middle initial from a text string however not all of the cells have middle initials. In column B I would like to return the first and last name. If needed I can have the first name in column B and the last in column C then combine them.

Example
John A Smith John Smith
John Smith John Smith

View 2 Replies View Related

Using VLOOKUP To Fill Data With A Partial String Match Separated With A Dash

Aug 18, 2014

I have a list of items in Column A and size info on Column B i want to being in the info to another sheet with a vlookup but the problem is that I have a lot of items with different colors so after the item no. it has a dash and a letter or two for the color so i want to bring into my new sheet all info.

I have in my old sheet for all items regardless of color so for instance in my old sheet i will BR1000-EM and then in my new sheet i will have BR1000-R and BR1000-SA and BR1000-YC how do i make a vlookup it should only lookup the values in both sheets only till the dash (i cant use a certain no. like left,6 because the item no can have more then 6 but it always has a dash when it has a color code) also not all items have dashes so the dash is not always there but when its there i would like that the lookup should stop by the dash.

View 6 Replies View Related

Custom Number Format - Em Dash For Zero

Dec 19, 2011

I know this works because I have seen it in a workbook at a client's office.

I need a custon number format to substiture an "em" dash for zero. An em dash is a hyphen with the width a the letter m. There is also the so called en dash tht is the width the the letter n. A search of the internet shows that to create an em dash in a cell that contains a 0 ("zero"), hold down the alt key and type 0151 on the numeric keypad. Typing 0150 insert a en dash.

I want to be able to set this up as a custom number format in the custom number dialog.

View 5 Replies View Related

If Cell Contains Dash And Symbol Surrounded On Both Sides By A Number Then True

Jan 13, 2012

I'm trying to make a formula but are failing. This is the data:

Cells:
a1= ant-gel
a2= ant - gel
a3 = size 1 - 6
a4 = size 1-6
a5 = book - 5
a6 = book-5
a7 = good book

I want a formula that displays "True" if cell contains a "-" symbol AND the dash symbol is surround on both sides by a number (a space can go between dash and number)

I want the results to go in column B

For example, if a1 contains a dash and dashes are surrounded on both sides by a number, then "TRUE", otherwise "FALSE.

therefore:
b1 = FALSE
b2 = FALSE
b3 = TRUE
b4 = TRUE
b5 = FALSE
b6 = FALSE
b7 = FALSE

View 2 Replies View Related

MID Formula: Extract Only The Text Between The 1st And 2nd Dash In A Cell

May 27, 2009

I need a formula that will extract only the text between the 1st and 2nd dash in a cell. Example:

10466193-1909457-
10648145-3026718-t526363536m

This formula would return only the following:

1909457
3026718

View 4 Replies View Related

Extract Number From Text String?

Apr 28, 2014

Below is a sample of data I need to extract the 8 digit number:

WO_32092_56228491_575482-113476-WP55
WO_32092_56228491_115130-WP55
WO_32092_56228491_115116-115118/115117-WP55
WO_32092_56228491_291881-318903-WP55
WO_259_56748761
WO_13895_52245652COUNTYRDN-30
WO_17368_51421730-A-ADDPOLEINFIELD
WO_17368_50885431-A-ADDMISSINGPOLE
WO_11021_52350485brock3377
In a spreadsheet, I had set up three columns where:

A: removed first three characters. WO_32092_56228491_115130-WP55 to 32092_56228491_115130-WP55
B: removed up to the _ . 32092_56228491_115130-WP55 to 56228491_115130-WP55
C: captured the first 8 characters left. 56228491_115130-WP55 to 56228491

I am pulling the data into Excel via an ODBC where there is thousands of rows of data. The three column process puts a tremendous strain on the processor.

Is there a formula that will extract the 8 character number without a three step process?

View 3 Replies View Related

Find Number Within A Text String Using VBA

Sep 4, 2009

I have a list of English game results with the score and the soccers of the game.

E.g. : [Steinsson 34, Davies 41, Elmander 46; Fuller 91]

As you can see in the excel, what Im trying to do is to find the time i.e which is the numbers in the field and display them seperately onto the cells beside. So what i need is to Find and extract these numbers 34,41,46,91 and paste them just beside cell on the list.

I can use formula but i can only display 1 number, so i think this might require a VBA script.Thanks in advance guys..

View 10 Replies View Related

Text String And I Want To Add A Number Automatically

Mar 6, 2008

I have in a cell a text string and I want to add a number automatically in the following rows. With other words

Product01
Product02
Product03
Etc
Product is a constant

How will I do this I know I can type the numbers and CONCATENATE it with the text part but I am too lazy to type out all the numbers to 1000

View 10 Replies View Related

Searching For A Number Within A Text String

Jun 2, 2009

I have a list of customers and account numbers contained within a cell. I need a formula if possible that searches from the right of the cell and then returns the all the numbers. e.g.

Arsenal1234Required formula result 1234
Liverpool2456Required formula result2456
Chelsea100564Required formula result100564

I can not use text to columns as they data is not consistant. Also worth noting is that the customer numbers vary fro 1 digit to 9 digits long.

View 5 Replies View Related

How To Pull Certain Number From Text String

Jul 16, 2012

I'm trying to pull a specific 10 digit number from a text string. The ID # is always 10 digits however sometimes there are dates in the data that need to be excluded as well as other numbers such as "I-9". The 10 digit number will always start with 1 or 8. Is there a macro or Formula to extract this data? Please find the example dataset below.

Edit: I should specify I want the "100118416" number from the first cell example or the "800011320" number from the 10th example.

NDM Abxx, Kexxxxx 100118416 2-29-12.pdf

VPG I9 Aberxxxxx, Dexxx 100113048 1-1-12.pdf

I-9 Abxxx, Rexx 100119966 4-5-12.pdf

NDM I9 Achxxxn, Paxx 100119008 3-15-2012.pdf

VPG I-9 Acxxxxx, Toxx 100112782 01-01-12.pdf

[code].....

View 9 Replies View Related

How To Add Spaces To A Number / Text String With VBA

Aug 10, 2013

I need to take 12ABC1234512345 and turn it into 12A BC 12345 12345 with a vba macro. I've made a formula that works but in this situation a macro would be more ideal.

View 5 Replies View Related

Finding A Number Within A Text String

Oct 28, 2007

I want to find a number within a text string, then count the letters in the same string, then add the number to the number of letters.

For example, if I have 9RR in a cell, I want to add 9 + 2 = 11.

The data will always be arranged with the number on the left side of the string.

So, if the number is a single digit, I know I can use left(A1) + len(A1) -1 to get my desired result. But, the trouble I am having is what if there is a double digit number like 10RR...I'm not quite sure how to create a formula (without using VBA) to give me a result of 12 for this cell.

View 9 Replies View Related

Returning Number From Text String

Jul 24, 2007

I have been trying a few formulas to return numbers from a string of text. The problem I am having is that there are more than one set of numbers that I need returned.

Here is an example of the text entered in F2

"K2PT bus structure [2 locations] & strain structure South West of L9L12-12 [1 location] / Use #4/0, std, cu conductor, connector Cat ID#10842 at structure leg & connector Cat ID#9655 at #4/0, std, cu gnd loop to connect #4/0, std, cu gnd loop to str leg."

What I need returned in a cell H2 is the numbers beside the Cat ID#

10842, 9655

I tried a Return Right Value formula, but I think because there are more than one possible value it isn't working properly.

View 5 Replies View Related

Parse Name & Number From Text String

Jan 11, 2008

I receive a text file daily of between 100 to 50,000 rows. It is a combination of many smaller text files or " records". Each record contains a row containing the name and some particulars . From 1 to 5 rows below that row there may or may not be a row containing the score for that record.

Here is an example of what the rows look like;

4505329 64036593 150090 MS MARY SMITH AB Finished
CRP 3.0 SCORE: 400

From the first row I need to pull out the second string of digits (ex 64036593) and the person's name. From the second row I need to extract the score (400). I would like to copy the three pieces of information to 3 separate columns on another sheet.
Comments
1. the word "Finished" always appears at the end of the row with the name in it but it also appears at the end of every record in it's own row like this;
Finished No Note
2. the strings of digits in the first row can vary in length but there are always 3 of them and they are always seperated by spaces.

I need to extract all the names and scores and put them in a table. If a name is not followed by a score I need to put "no score".

View 9 Replies View Related

Text Number String To Number

Oct 24, 2008

I am looking for a way to add the 123 plus 456 to get 579. I have had some ideas that almost work, but I cannot get rid of the ' .

View 11 Replies View Related

Extracting Phone Number Out Of String Of Text?

Apr 30, 2013

Is there a way to extract a phone number out of a string of text. The phone number will always be expressed the same way (eight digits seperated by a space half way through) - 9999 9999. But the text before and after the number is random. Is there a macro to do this on a large scale? The method needs to be applied to hundreds of these strings, each on a new line.

An example of the string of text with the phone number underlined:

Alesdro 0 63PnantCey4281 5919 Aledio daSisaon' Brglry

View 7 Replies View Related

Extracting Number From Inconsistent Text String

Jul 4, 2014

I have an excel stock price template, where I need the current price to calculate the mid point if the chart.

This is the text I get from the webquery

Underlying stock: SBIN 2699.00 as on Jul 04, 2014 15:30:36 IST

I need a formula to extract the stock price '2699.00' only from this text.

The problems are sometimes its may change to underlying "stock" to "index", SBIN to RELIANCE or TATASTEEL, and the price some times two digit say 16, some times 6 letters say 150.05, or 8 digits say 15160.00

Formula, the text in B1 and need the price at A100.

View 9 Replies View Related

Pull Number From Middle Of Text String

Mar 24, 2009

I would like one formula to remove "5206" from this string. I tried a combination of right/left formulas together, but I could not get it to work.

5032.5206.05816.00040501.0000

View 9 Replies View Related

Vlookup On Only Part Of A Text/number String

May 5, 2009

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.

View 10 Replies View Related

Count Number Of Characters In String/Text

Aug 24, 2006

If 'a' is a string that contains x number of characters, how do I find out what x is (in VBA)?

View 2 Replies View Related

Match All Text And Closest Number In Alphanumeric String?

Feb 21, 2014

Formula to match all text and closest number in alphanumeric string

View 1 Replies View Related

Count Number Of Time A Text String Appears

May 25, 2007

I have a very large spreadsheet and want to count the number of times a particular text string shows up in a column. I can't use autofilter due to the 1000 limit.

Here's an example, Column C contains:
Dan Parker
John Doe
Dan Smith
Jill Smith

So if I search on *Dan*, the function should return a count of 2.

I've used COUNTIF before to return values when the whole cell = a certain value but in my case the cell may have 200 characters and I want to count based on a fuzzy search. I would like to do this in a function and not a macro.

View 14 Replies View Related

Extracting Number Of Seconds From Variable Text String?

Oct 2, 2011

I have a column of cells, each with a with text string that has three possible formats where I want to extract the total number of seconds.

The three formats are:

nnn hrs nn min nn sec (example: 1 hrs 42 min 58 sec)
or
nn min nn sec (example: 55 min 1 sec)
or
nn sec (example: 10 sec)

The result I want is a numeric value of the total number of seconds in the text string.

For example a text string of: 1 hrs 42 min 58 sec

Should give the result: (1 x 3600) + (42 x 60) + 58 = 6,178

View 9 Replies View Related

Extract Number Of Variable Length From Text String

Jan 25, 2007

Imagine that I have this list of thousands of customers, who are listed in column B in the format "customer no+space+customer name".

Now I want to extract ONLY the customer no from the text string in column B and insert it as number value in column A on the same row.

Would have been easy with "Left" command, but as the customer numbers have variable length, I have a problem.

View 5 Replies View Related

Find Variable Size Number Within Text String

Sep 20, 2007

I have a spreadsheet with a couple of hundred rows on each tab that looks like this: A1: #1 PENROSE TIJUANA MAMA PCH 2620039190 665794 12.00 CT 1 Front 1 1 1. The only constant is the 10 digit number followed by the 6 digit number in the middle and I want to use it to parse the text string. I want the output to be everything prior to the 10 digit number in A1, the 10 digit number in B1, the 6 digit number in c1 and everything else in D1 and so on through the rows.

View 4 Replies View Related

How To Append Sequential Number To A Text String To Avoid Duplicates

Jun 12, 2014

Is there a formula that will add a number, in sequence, to the end of a text string to avoid duplicates?

I need to generate an ID number for transactions. This ID number is the Account Code-Last Two #s of the Year-Unique 3-Digit Number. So for instance, 5022-14-001 means it is the first transaction from account 5022 in the year 2014.

Column A has the Account Codes. Column B has the date of the transaction in MM/DD/YYYY format. So far the formula I have is:

=CONCATENATE(A1,"-",RIGHT(YEAR(B2),2),"-",TEXT(????,"000"))

With ???? being some function or set of nesting functions I need to create the sequential number. It needs to be able to say "Okay, this is the third instance of there being a 5022-14, so we need to stick -003 at the end of this."

Additionally, this "003" needs to be frozen, so if we change how the sheet is sorted and the line item moves around, it will still always be "003".

View 7 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved