title: UIPasteboard: NSString refuses to copy to clipboard
body: <p>I have the following code to shorten a URL using the bit.ly API.</p>
  
  <pre><code>NSString *shortenedURL = [NSString stringWithContentsOfURL:[NSURL URLWithString:[NSString stringWithFormat:@"http://api.bit.ly/v3/shorten?login=%@&amp;apikey=%@&amp;longUrl=%@&amp;format=txt", login, key, self.link.text]] encoding:NSUTF8StringEncoding error:nil];
  </code></pre>
  
  <p>I also have the following code to copy the shortened URL to the pasteboard:</p>
  
  <pre><code>UIPasteboard *pasteboard = [UIPasteboard generalPasteboard];
  pasteboard.string = shortenedURL;
  </code></pre>
  
  <p>However, this does not work. In the output log, this is what is displayed:</p>
  
  <pre><code>*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIPasteboard setString:]: Argument is not an object of type NSString [(null)]'
  </code></pre>
  
  <p>So if the argument isn't an object, what is it? I tried assuming it was a URL with this:</p>
  
  <pre><code>UIPasteboard *pasteboard = [UIPasteboard generalPasteboard];
  pasteboard.URL = shortenedURL;
  </code></pre>
  
  <p>The same type of error is produced, only saying that the argument is not an <code>NSURL</code> object, instead of the previous error saying the argument is not an <code>NSString</code> object.</p>
  
  <pre><code>*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIPasteboard setURL:]: Argument is not an object of type NSURL [(null)]'
  </code></pre>
  
  <p>Anyone know what to do? </p>