ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Extract From Cell (https://www.excelbanter.com/excel-worksheet-functions/60265-extract-cell.html)

WDP

Extract From Cell
 
Hi:

I have data in the following format:

\\192.100.1.94\documents and settings\user\my documents\file.pst

I want to extract the IP address from this line...ie....192.100.1.94

I guess I am looking for a function that will look for the only instance of
"\\" in the line....and then give me everything to the right (up to the 1st
instance of "\"

Can anyone help

Thanks
Warren Phillips

Gary''s Student

Extract From Cell
 
Select the cells and pull-down:

Data Text to Columns... and tell the wizard to use the backslash as the
separator.

This will split the text into parts.
--
Gary's Student


"WDP" wrote:

Hi:

I have data in the following format:

\\192.100.1.94\documents and settings\user\my documents\file.pst

I want to extract the IP address from this line...ie....192.100.1.94

I guess I am looking for a function that will look for the only instance of
"\\" in the line....and then give me everything to the right (up to the 1st
instance of "\"

Can anyone help

Thanks
Warren Phillips


Sloth

Extract From Cell
 
=MID(A1,3,FIND("\",A1,3)-3)

"WDP" wrote:

Hi:

I have data in the following format:

\\192.100.1.94\documents and settings\user\my documents\file.pst

I want to extract the IP address from this line...ie....192.100.1.94

I guess I am looking for a function that will look for the only instance of
"\\" in the line....and then give me everything to the right (up to the 1st
instance of "\"

Can anyone help

Thanks
Warren Phillips


bpeltzer

Extract From Cell
 
If the format always begins with \\, then =MID(a1,3,FIND("\",a1,3)-3) give
you everything right of that up until the next \ (this will fail if there is
no subsequent \ character!).


"WDP" wrote:

Hi:

I have data in the following format:

\\192.100.1.94\documents and settings\user\my documents\file.pst

I want to extract the IP address from this line...ie....192.100.1.94

I guess I am looking for a function that will look for the only instance of
"\\" in the line....and then give me everything to the right (up to the 1st
instance of "\"

Can anyone help

Thanks
Warren Phillips


WDP

Extract From Cell
 
Everyone:

All these suggestions gave me the excact data I needed.

Thank you for your time in responding




"WDP" wrote:

Hi:

I have data in the following format:

\\192.100.1.94\documents and settings\user\my documents\file.pst

I want to extract the IP address from this line...ie....192.100.1.94

I guess I am looking for a function that will look for the only instance of
"\\" in the line....and then give me everything to the right (up to the 1st
instance of "\"

Can anyone help

Thanks
Warren Phillips



All times are GMT +1. The time now is 08:28 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com