void CreateWcfDto_Click(object sender, EventArgs args) { var gen = new GenDto((ModelType)this.DataInfo); StringBuilder builder = new StringBuilder(); gen.Generate(builder); this.OnGenerate(this, builder); }