• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Find and Replace Text
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Find and Replace Text


  • Subject: Re: Find and Replace Text
  • From: Robert Stretch <email@hidden>
  • Date: Thu, 25 Apr 2002 10:21:59 +1000

Hi there,

Well I'm not sure whether this completely suits your purposes or not, but I too had a similar problem to you and got around it in this way:

1) I loaded the text of the script using the unix command 'cat' which is a text editor eg: "do shell script ("cat /some/folder/and/file")"
2) Apply a variable to the result of that eg: "set var to the result"
3) Now search for an 'offset' of a string of text in that variable eg: "offset of "wateva" in var". That will give you the character number
in the variable that the word begins at.

Once you know what character number the string you are looking for begins at, you could use AppleScript's Text Item Delimiters to
divide up the text using a common separator.

Hope this has been of some use!
Rob
_______________________________________________
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.

  • Prev by Date: Re: Tanaka's osax 2.01- MT Parse command ??
  • Next by Date: Re: force quit a classic app
  • Previous by thread: Re: Find and Replace Text
  • Next by thread: Re: Find and Replace Text
  • Index(es):
    • Date
    • Thread