title: AppleScript: Path to Current Application
body: <p>Quick question. I'm trying to get the path to the current application using AppleScript (a Cocoa AppleScript app). Basically, I'm trying to determine where the app is located so that I can manipulate a file that is within a folder in the disk image with the app. I was wondering if there is a more straightforward way of returning the path, I currently have:</p>
  
  <pre><code>set Var1 to (path to current application as text) &amp; "Resources:File.xml"
  </code></pre>
  
  <p>Which returns: "Macintosh HD:Applications:Utilities:Script Editor.app:Resources:File.xml"</p>
  
  <p>That's fine, except that I want to omit the name of the app in the path. I know I can do this with some text manipulation, but I have to assume there is a cleaner way other than cutting it up in to parts. Thanks!</p>