Re: Find and Replace Text
Re: Find and Replace Text
- Subject: Re: Find and Replace Text
- From: David Wignall <email@hidden>
- Date: Thu, 25 Apr 2002 15:08:19 +1200
on 25/4/02 4:44 am, Eric Phillips at email@hidden wrote:
<snip>
>
I have some text that I used OCR to get an electronic version. I want to get
>
it into excel but it needs modification to get it into the correct columns.
>
The text itself can have commas between words, I would like to keep that
>
format intact. What I want to change is when there is a 'Word,SpaceNumber'. I
>
would like the number in the next cell so I would like to change the ',Space'
>
to a 'Tab'. If I import the file as comma delimited then where the words are
>
separated by commas gets all messed up. My knowledge of using AppleScript to
>
do all that string manipulation is quite limited. I was thinking about using
>
something like MS Word and script it to do find and replace.
I would get Excel to do the whole thing on it's own; no need to fiddle with
the spaces as they can be delimiters in their own right.
tell Application "Microsoft Excel"
OpenText "(filepathname here)" DataType xlDelimited with
TreatConsecutiveDelimitersAsOne and SpaceDelimiter -- one line
end tell
--
hth
Dave
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.