title: How to parse Skype response with AppleScript?
body: <p>Essentially, I need to parse the response string of the CHAT CREATE command with AppleScript to get the chatid. The response looks like:</p>
  
  <blockquote>
    <p>CHAT #my.username/$123abc456blah STATUS MULTICHAT</p>
  </blockquote>
  
  <p>I tried</p>
  
  <pre><code>set chatid to item 2 of response
  </code></pre>
  
  <p>but that returns 'H' -- I also tried </p>
  
  <pre><code>set chatid to word 2 of response
  </code></pre>
  
  <p>but that returns 'my'. I imagine this is an easy question for someone that knows AppleScript. Here is a sample script...</p>
  
  <pre><code>tell application "Skype"
      set response to (send command "CHAT CREATE username1, username2" script name "MyScript")
      set chatid to ***WHAT GOES HERE?***
      send command "ALTER CHAT " &amp; chatid &amp; " SETTOPIC Hello" script name "MyScript"
  end tell
  </code></pre>