• 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: Searching for the equivalent of coercing to type "record"
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Searching for the equivalent of coercing to type "record"


  • Subject: Re: Searching for the equivalent of coercing to type "record"
  • From: John Delacour <email@hidden>
  • Date: Sat, 8 Mar 2003 00:33:27 +0000
  • Mac-eudora-version: 6.0a10

At 6:19 pm -0500 7/3/03, Steve Cunningham wrote:

Thanks, Paul. That sucks about the vertical bars, however. I have
realized that since the field names in my text file have spaces in them
also, I will not be able to turn them into record field names after all.

I'll file this away for the next time I have a file without mixed cases
and spaces in the name :-)

You can still do it:



set _text to "home phone 123 work phone 234
cell phone 345 mega phone 999" -- make sure you have tabs!

set ls to paragraphs of _text
set _text to ls as string
set my text item delimiters to tab
set ls to text items of _text
set my text item delimiters to "\",\""
set _record to run script "{<<class usrf>>:{\"" & ls & "\"}} as record"

|work phone| of _record
--> 234
|mega phone| of _record
--> 999
_______________________________________________
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.

References: 
 >Re: Searching for the equivalent of coercing to type "record" (From: Steve Cunningham <email@hidden>)

  • Prev by Date: Re: Move message to another mailbox behaves erratically?
  • Next by Date: Re: Searching for the equivalent of coercing to type "record"
  • Previous by thread: Re: Searching for the equivalent of coercing to type "record"
  • Next by thread: Re: Searching for the equivalent of coercing to type "record"
  • Index(es):
    • Date
    • Thread