Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
My field CombMod in huge database contains entries with
unnecessary semi colons in different places. I need a macro to remove them. For Eaxmple ;PM;;;LE;;;;; to become PM;LE ;PM;;PP PL;PP OP;PP PK;;;;;;QM to become PM;PP PL;PP OP;PP PK;QM Please help |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Function SemiClean(MyStr As String) As String
Dim NewStr As String NewStr = Replace(MyStr, ";;", ";") If Mid(NewStr, 1, 1) = ";" Then NewStr = Right(NewStr, Len(NewStr) - 1) If Right(NewStr, 1) = ";" Then NewStr = Left(NewStr, Len(NewStr) - 1) If InStr(NewStr, ";;") Then NewStr = Clean(NewStr) SemiClean = NewStr End Function "JA" wrote: My field CombMod in huge database contains entries with unnecessary semi colons in different places. I need a macro to remove them. For Eaxmple ;PM;;;LE;;;;; to become PM;LE ;PM;;PP PL;PP OP;PP PK;;;;;;QM to become PM;PP PL;PP OP;PP PK;QM Please help |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
=SUBSTITUTE(C4,"~?#","") will this work to remove multiple string | Excel Worksheet Functions | |||
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell | Excel Discussion (Misc queries) | |||
How do I create a macro to remove path from hyperlink "address"? | Excel Discussion (Misc queries) | |||
Macro to concatenate into "B1" B2 thru B"x" based on new data in "Col A" | Excel Discussion (Misc queries) | |||
Sending macro based e-mail with built-in "Heading" and "Text" | Excel Programming |