• 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: More weird Unicode things
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: More weird Unicode things


  • Subject: Re: More weird Unicode things
  • From: kai <email@hidden>
  • Date: Fri, 3 Jun 2005 22:40:29 +0100


On Friday, June 3, 2005, at 11:17 am, jj wrote:

pathnameandparent(choose file)

to pathnameandparent(f)
    set AppleScript's text item delimiters to "/"
    set f to (POSIX path of f)'s text items
    set parentDir to items 1 thru -2 of f as Unicode text
    set fileName to item -1 of f
    set AppleScript's text item delimiters to {""}

    return {fileName, parentDir}
end pathnameandparent

What happens there if you try this variation, jj?

-----------------

pathnameandparent(choose file)

to pathnameandparent(f)
	set AppleScript's text item delimiters to "/"
	tell (POSIX path of f)
		set parentDir to text 1 thru text item -2 & "/"
		set fileName to text item -1
	end tell
	set AppleScript's text item delimiters to {""}

	return {fileName, parentDir}
end pathnameandparent

-----------------

---
kai

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: More weird Unicode things
      • From: jj <email@hidden>
References: 
 >More weird Unicode things (From: jj <email@hidden>)

  • Prev by Date: Re: Adding To A List
  • Next by Date: Re: Distiller Sample Line?
  • Previous by thread: Re: More weird Unicode things
  • Next by thread: Re: More weird Unicode things
  • Index(es):
    • Date
    • Thread