Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Extract Characters
I am trying to Extract characters out of a string and include them in a file name by using Dim sName As String sName = (Left(B1, 3) & Right(B1, 2)) But this does not work. Any ideas as to what is wrong? Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Extract Characters
sName = (Left(range("B1"), 3) & Right(range("B1"), 2))
or better: Function sName (rngS as range) as string 'or variant Dim sName As String sName = (Left(rngS, 3) & Right(rngS, 2)) end Function Stephen Rasey Houston http://excelsig.org http://wiserways.com "Jack S" wrote in message ... I am trying to Extract characters out of a string and include them in a file name by using Dim sName As String sName = (Left(B1, 3) & Right(B1, 2)) But this does not work. Any ideas as to what is wrong? Thanks |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Extract Characters
-----Original Message----- sName = (Left(range("B1"), 3) & Right(range("B1"), 2)) or better: Function sName (rngS as range) as string 'or variant Dim sName As String sName = (Left(rngS, 3) & Right(rngS, 2)) end Function Stephen Rasey Houston http://excelsig.org http://wiserways.com "Jack S" wrote in message ... I am trying to Extract characters out of a string and include them in a file name by using Dim sName As String sName = (Left(B1, 3) & Right(B1, 2)) But this does not work. Any ideas as to what is wrong? Thanks . Thanks for your help. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
extract last 2 characters from the right? | Excel Worksheet Functions | |||
Extract characters from Right of string | Excel Worksheet Functions | |||
Extract characters from a cell | Excel Discussion (Misc queries) | |||
Extract the first few characters | Excel Worksheet Functions | |||
HOW DO I EXTRACT ALL CHARACTERS AFTER 5 CHARACTERS ON LEFT | Excel Worksheet Functions |