title: AppleScript: Getting a list of all properties of an object or class
body: <p>In order to store an object's values for external (outside AS) access, I need to be able to get every property of that object, and then I'd try to coerce it to text and store it somehwere.</p>
  
  <p>How do I get the list of properties that an object holds. As an example, I can write this:</p>
  
  <pre><code>tell me
    get properties
  end tell
  </code></pre>
  
  <p>That works for a <em>script</em> object.</p>
  
  <p>But for many other objects, I simply get an error such as "descripter type mismatch", like here:</p>
  
  <pre><code>tell application "iTunes"
    get properties of file track 1
  end tell
  </code></pre>
  
  <p>Now, I know the excellent <strong>Script Debugger can do it</strong> (it can show any object's entire set of properties), so it should be possible in written AppleScript as well. What's the secret to this?</p>