namespace Sample
{
using System;
using System.Collections;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Web;
using System.Web.SessionState;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;
public class FacadeCodeAspx : System.Web.UI.Page
{
protected System.Web.UI.WebControls.TextBox TextBox1;
}
}
namespace Sample
{
using System;
using System.Collections;
using System.ComponentModel;
using System.Text;
using System.IO;
using System.Reflection;
using System.Web;
using System.Web.UI;
public class FacadeCodeMaker
{
Type type;
PropertyDescriptorCollection pdc;
StringBuilder sb=new StringBuilder();
System.CodeDom.Compiler.IndentedTextWriter w;
string classname;
public FacadeCodeMaker(Type t)
{
type=t;
pdc=TypeDescriptor.GetProperties(type);
w=new System.CodeDom.Compiler.IndentedTextWriter(new StringWriter(sb));
classname=type.Name+"Facade";
w.WriteLine("[System.AttributeUsage(System.AttributeTargets.Property)]");
w.WriteLine("public class DescriptionAttribute:System.ComponentModel.DescriptionAttribute{");
w.Indent++;