【c#】 組件取得類別型別
Assembly.Load("Assembly.Namespace").GetType("Assembly.Namespace.ClassName");
EXEC sp_rename 'TableName.OldColName','NewColName','column'
var document = new HtmlToPdfDocument
{
GlobalSettings =
{
ProduceOutline = true,
DocumentTitle = "PDF Title",
PaperSize = System.Drawing.Printing.PaperKind.A4,
Orientation = TuesPechkin.GlobalSettings.PaperOrientation.Landscape,
Margins =
{
Top = 1.5,
Right = 1,
Bottom = 1,
Left = 1.25,
Unit = Unit.Centimeters
}
},
Objects = {
new ObjectSettings { PageUrl = URL }
}
}
IPechkin sc2 = Factory.Create();
var buf = sc2.Convert(document);
Response.Clear();
Response.HeaderEncoding = System.Text.Encoding.GetEncoding(950);
Response.AddHeader("Content-Disposition", "attachment; filename=Filename.pdf");
Response.ContentType = "application/octet-stream";
Response.BinaryWrite(buf);
Type type = Nullable.GetUnderlyingType(propertyInfo.PropertyType) ?? propertyInfo.PropertyType; propertyInfo.SetValue(model, Convert.ChangeType(ObjectValue, type), null);