In a medium sauce pan melt butter over med. heat.Add in the flour and stir till combined. Now add the milk and cook until the milk mixture is thickened. When thickened add the corn , salt and pepper and sugar. Remove from heat and add the beaten eggs and mix till well combined. Place in to greased baking dish and bake in a 350 oven until brown and custard like. I am guessing about 45 minute or more.