title: The 'await' operator can only be used within an async lambda expression
body: <p>I've got a c# Windows Store app. I'm trying to launch a <code>MessageDialog</code> when one of the command buttons inside another <code>MessageDialog</code> is clicked. The point of this is to warn the user that their content is unsaved, and if they click cancel, it will prompt them to save using a separate save dialog. </p>
  
  <p>Here's my "showCloseDialog" function: </p>
  
  <pre><code>private async Task showCloseDialog()
  {
      if (b_editedSinceSave)
      {
          var messageDialog = new MessageDialog("Unsaved work detected. Close anyway?", "Confirmation Message");
  
          messageDialog.Commands.Add(new UICommand("Yes", (command) =&gt;
          {
              // close document
              editor.Document.SetText(TextSetOptions.None, "");
          }));
  
          messageDialog.Commands.Add(new UICommand("No", (command) =&gt;
          {
              // save document
              await showSaveDialog();
          }));
  
          messageDialog.DefaultCommandIndex = 1;
          await messageDialog.ShowAsync();
      }
  }
  </code></pre>
  
  <p>In VS I get a compiler error:</p>
  
  <blockquote>
    <p>The 'await' operator can only be used within an async lambda expression. Consider marking this lambda expression with the 'async' modifier`</p>
  </blockquote>
  
  <p>The method is marked with <code>await</code>. If I remove <code>await</code> from before showSaveDialog, it compiles (and works) but I get a warning that I really should use <code>await</code></p>
  
  <p>How do I use <code>await</code> in this context? </p>