title: How to convert a Object String to Object Guid in C#
body: <p>I have a DetailsView, I need get the value specifield in DataKeyNames "UserId" (a Guid Field) and add it to an Object Guid.</p>
  
  <p>At the moment I am using this code:</p>
  
  <pre><code>String myUserId = (String)uxAuthorListDetailsView.DataKey["UserId"].ToString();
  </code></pre>
  
  <p>but I would need something like:</p>
  
  <pre><code>Guid myUserGuid = (Guid)uxAuthorListDetailsView.DataKey["UserId"].ToString();
  </code></pre>
  
  <p>But does not work I get error Error </p>
  
  <pre><code>Cannot convert type 'string' to 'System.Guid'
  </code></pre>
  
  <p>What could be the problem? Thanks guys for your support!</p>