Featured

C# : OWIN – Environment Elements and Another Way of Information Passing

Earlier this week I ended up in a situation where, a signal flag wanted to be set in a controller method which will eventually invoke the¬†RedirectToIdentityProvider notification where the signal flag value has to be checked and retrieved. Usually the¬†RedirectToIdentityProvider notification is getting called when SignIn(), SignOut() or Challange() methods are getting called. I was […]

Read More C# : OWIN – Environment Elements and Another Way of Information Passing
Featured

EF : Code First – Auto Increment Key

No need for an explanation for the subject. Its a general scenario to have an auto incremental key column in DB. So, we can use [Key] [DatabaseGenerated(DatabaseGeneratedOption.Identity)] attributes for the purpose, for example : namespace CustomerBase.Models { using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; public partial class Customer { [Key] [DatabaseGenerated(DatabaseGeneratedOption.Identity)] public int Id { get; set; } […]

Read More EF : Code First – Auto Increment Key