View Single Post
  #9   Report Post  
Posted to microsoft.public.excel.programming
isabelle isabelle is offline
external usenet poster
 
Posts: 587
Default Easy Problem b/c I am not an Excel Expert

hi,

Sub Macro1()
t1 = "1969 Corvette Bumper - Chrome Retainers included - quality rating of 10- ETA: 07/30/12."
t2 = "ETA " & Split(t1, "ETA")(1)
End Sub

--
isabelle



Le 2012-07-25 12:30, Anthony232 a écrit :
Here is my problem...Included at the end of our product descriptions, we
sometimes include "ETA's". For example, our product description (which
can be up to 300 characters) could read"

1969 Corvette Bumper - Chrome Retainers included - quality rating of 10
- ETA: 07/30/12.

What I am trying to do is to remove the ETA: 07/30/12. I tried to Find
and Replace all "ETA:" with about 500 @ symbols. Then, I was going to do
Text to Columns and choose Fixed Width...setting the cutoff point at the
longest product description in the sheet...at character # 301 for
example. Doing this would push everything after the ETA way to the
right. I was then going to delete the second column that it
created...getting rid of most of the @ symbols, and ALL dates. Finally,
I would Find and Replace all @ symbols in the first (original) column
leaving me with just the description.

I know this is the long way, but I am no Excel Expert, so this is one
way for me to get it done...but here's my problem....

Looking at the example above, I tried to use the formula =Substitute(A1,
("ETA"), "@@@@@@") BUT, when I use this formula, it replaces the ETA AND
the ETA in the word rETAiners. I thought that if I used "" around the
actual letters that I am looking for, it would ONLY replace exact
matches....retainers is NOT an exact match for ETA, and no matter what I
try, it will not replace ETA without replacing rETAiners also!

Just to break my problem down and figure out how to single out exact
matches, I was using the FIND function and trying to FIND exact matches
for "ETA:" and it kept coming up with an error saying that excel
couldn't find any matches. However, if I did a FIND for just ETA, it
found them all...standalone and in words.

So, if you can help me with my original plan, that would be ok, but if
you could help me delete EVERYTHING after the word ETA with blanks, that
would be a lot easier. Another problem is that sometimes its ETA, and
other times it's ETA: So, I think I will have to run whatever process
you help me come up with twice. Once for the exact match of ETA, and
again with the exact match of ETA:

Thank you SOOOOOOOOO much...I have spent about 3 hours on this so far
and my deadline was yesterday!

.:M


+-------------------------------------------------------------------+
+-------------------------------------------------------------------+