ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   copy select characters from specified cells. (https://www.excelbanter.com/excel-worksheet-functions/113539-copy-select-characters-specified-cells.html)

Ron

copy select characters from specified cells.
 
I'm trying to build on an answer I received last week (which was very
helpfull).

I'm using the below formula to conditionally copy the data from the fourth
cell over - or leave the field blank if the word 'Named' is not in the 4th
column.

=IF(ISNUMBER(SEARCH("[ Named",C[4])),C[4],"")

I need to expand on the copy portion as I need to conditionally copy the
contents of C[4] and to always ignore the first 20 characters and the last 2
characters from C[4].

example input from C[4]:
[ Named Symbology - T_Flow Line CBC ]
000Default LineLineSymbology
001Default TextTextSymbology

[ Named Symbology - T_Flow Line of StreamRiver ]
000Default LineLineSymbology
001Default TextTextSymbology


Gary L Brown

copy select characters from specified cells.
 
Try this...
=IF(ISNUMBER(SEARCH("[ Named",C[4])),mid(C[4],21,LEN(C[4])-21-2+1),"")
untried formula.
HTH,
--
Gary Brown

If this post was helpful, please click the ''Yes'' button next to ''Was this
Post Helpfull to you?''.


"Ron" wrote:

I'm trying to build on an answer I received last week (which was very
helpfull).

I'm using the below formula to conditionally copy the data from the fourth
cell over - or leave the field blank if the word 'Named' is not in the 4th
column.

=IF(ISNUMBER(SEARCH("[ Named",C[4])),C[4],"")

I need to expand on the copy portion as I need to conditionally copy the
contents of C[4] and to always ignore the first 20 characters and the last 2
characters from C[4].

example input from C[4]:
[ Named Symbology - T_Flow Line CBC ]
000Default LineLineSymbology
001Default TextTextSymbology

[ Named Symbology - T_Flow Line of StreamRiver ]
000Default LineLineSymbology
001Default TextTextSymbology


Gary L Brown

copy select characters from specified cells.
 
=IF(ISNUMBER(SEARCH("[ Named",C[4])),mid(C[4],21,LEN(C[4])-21-2+1),"")
--
Gary Brown

If this post was helpful, please click the ''Yes'' button next to ''Was this
Post Helpfull to you?''.


"Ron" wrote:

I'm trying to build on an answer I received last week (which was very
helpfull).

I'm using the below formula to conditionally copy the data from the fourth
cell over - or leave the field blank if the word 'Named' is not in the 4th
column.

=IF(ISNUMBER(SEARCH("[ Named",C[4])),C[4],"")

I need to expand on the copy portion as I need to conditionally copy the
contents of C[4] and to always ignore the first 20 characters and the last 2
characters from C[4].

example input from C[4]:
[ Named Symbology - T_Flow Line CBC ]
000Default LineLineSymbology
001Default TextTextSymbology

[ Named Symbology - T_Flow Line of StreamRiver ]
000Default LineLineSymbology
001Default TextTextSymbology


Ron

copy select characters from specified cells.
 
Works like a champ! I was not aware of the mid function. Thank you!!!

"Gary L Brown" wrote:

=IF(ISNUMBER(SEARCH("[ Named",C[4])),mid(C[4],21,LEN(C[4])-21-2+1),"")
--
Gary Brown

If this post was helpful, please click the ''Yes'' button next to ''Was this
Post Helpfull to you?''.


"Ron" wrote:

I'm trying to build on an answer I received last week (which was very
helpfull).

I'm using the below formula to conditionally copy the data from the fourth
cell over - or leave the field blank if the word 'Named' is not in the 4th
column.

=IF(ISNUMBER(SEARCH("[ Named",C[4])),C[4],"")

I need to expand on the copy portion as I need to conditionally copy the
contents of C[4] and to always ignore the first 20 characters and the last 2
characters from C[4].

example input from C[4]:
[ Named Symbology - T_Flow Line CBC ]
000Default LineLineSymbology
001Default TextTextSymbology

[ Named Symbology - T_Flow Line of StreamRiver ]
000Default LineLineSymbology
001Default TextTextSymbology



All times are GMT +1. The time now is 02:24 PM.

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