本文整理汇总了C#中CodeGenerator类的典型用法代码示例。如果您正苦于以下问题:C#CodeGenerator类的具体用法?C#CodeGenerator怎么用?C#CodeGenerator使用的例子?这里精选的类代码示例或许可以为您提供帮助。
示例1:Page_Load
protectedvoidPage_Load(objectsender,EventArgse)
{
try
{
Parameter=ProjectParameter.GetSettingsByProjectName(CurrentSession.UserCode,ProjectName);
Generator=newCodeGenerator(Parameter);
ColumnInfos=Generator.GetColumnsInfo(TableName,PrimaryKeyOverwrite);
ReferFolder=Path.Combine(Server.MapPath(".."),"Manage\Refer");
OutputFolder=Path.Combine(Server.MapPath(".."),string.Concat("Manage\",CurrentSession.UserCode,"\",TableName));
if(!System.IO.Directory.Exists(OutputFolder))System.IO.Directory.CreateDirectory(OutputFolder);
switch(type)
{
case1:
Search();
Callback();
Result();
Edit();
GetTogether.Mapping.MappingInfoCache.Caches.Clear();
if(!string.IsNullOrEmpty(Request["download"]))
Compress(OutputFolder,string.Concat(OutputFolder,"-Management.zip"));
break;
default:
break;
}
JsonSuccess();
}
catch(Exceptionex)
{
JsonError(ex.Message);
}
}
原文链接:
http://www.jxszl.com/biancheng/C/556802.html