title: The type ApplicationUser cannot be used as type parameter 'TUser' in the generic type or method 'IdentityDbContext<TUser>'
body: <p>Trying to implement Identity in ASP.NET Core 2.0.  Having many problems getting my head around this.</p>
  
  <p><strong>Startup.cs</strong></p>
  
  <pre><code>public class Startup
  {
      public Startup(IConfiguration configuration)
      {
          Configuration = configuration;
      }
  
      public IConfiguration Configuration { get; }
  
      // This method gets called by the runtime. Use this method to add services to the container.
      public void ConfigureServices(IServiceCollection services)
      {
          services.AddDbContext&lt;ApplicationDbContext&gt;(options =&gt;
              options.UseSqlServer(Configuration.GetConnectionString("Ctrack6_Custom"))
          );
  
  
          services.AddIdentity&lt;ApplicationUser, ApplicationRole&gt;()
              .AddEntityFrameworkStores&lt;ApplicationDbContext&gt;()
              .AddDefaultTokenProviders();
  
  etc...
  </code></pre>
  
  <p><strong>ApplicationUser.cs</strong> Using Guid for key.  Also set in Role, etc</p>
  
  <pre><code>// Add profile data for application users by adding properties to the ApplicationUser class
  public class ApplicationUser : IdentityUser&lt;Guid&gt;
  {
      [MaxLength(50)]
      public string FirstName { get; set; }
  
      [MaxLength(50)]
      public string LastName { get; set; }
  
      [MaxLength(5)]
      public string OrgCode { get; set; }
  
      public ApplicationUser() : base()
      {
  
      }
  
  }
  </code></pre>
  
  <p><strong>ApplicationDbContext.cs</strong> Error is thrown in this file on the class definition.  ApplicationDbContext is throwing this error:</p>
  
  <blockquote>
    <p>The type 'App.Identity.ApplicationUser' cannot be used as type parameter 'TUser' in the generic type or method 'IdentityDbContext'. There is no implicit reference conversion from 'App.Identity.ApplicationUser' to 'Microsoft.AspNetCore.Identity.IdentityUser'. </p>
  </blockquote>
  
  <pre><code>public class ApplicationDbContext : IdentityDbContext&lt;ApplicationUser&gt;
  {
      public ApplicationDbContext(DbContextOptions&lt;ApplicationDbContext&gt; options)
          : base(options)
      {
      }
  
      protected override void OnModelCreating(ModelBuilder builder)
      {
          base.OnModelCreating(builder);
          // Customize the ASP.NET Identity model and override the defaults if needed.
          // For example, you can rename the ASP.NET Identity table names and more.
          // Add your customizations after calling base.OnModelCreating(builder);
          builder.Entity&lt;blah&gt;()
          .HasKey(c =&gt; new { fields, for, key });
  
      }
  
      public DbSet&lt;etc&gt; Etcs {get; set; }
  
  }
  </code></pre>