title: Dismiss native UIActionsheet & UIPopover in iPad
body: <p>This question refers to the native iOS function of displaying actionsheets and popovers when a phone number or email is selected in a webview/textview from an iPad.  In case you need a refresher, the actionsheet contains two buttons that read "Add to Contacts" and "Copy".  Where the popover that I am referring to is what is displayed when the user selects the "Add to Contacts" button.</p>
  
  <p>I understand that to dismiss a popover one declares:</p>
  
  <pre><code>[somePopoverController dismissPopoverAnimated:YES];
  </code></pre>
  
  <p>To dismiss an actionsheet, one can simply call:</p>
  
  <pre><code>[someActionSheet dismissWithClickedButtonIndex:0 animated:YES];
  </code></pre>
  
  <p>However, my problem is that since iOS created these actionsheets/popovers for me, I do not own them, and cannot reference them to call the dismiss methods. </p>
  
  <p>The use case of why I need to do this is because my application will log the user out after a specified time of no activity. When the user is logged out these actionsheets/popovers still remain on the screen, even though I have entered a new view controller and removed the old ones.  </p>
  
  <p>Does anyone know of how I can reference these popovers and  actionsheets that I do not own? Any advice would be greatly appreciated!</p>