new ActiveXObject("Excel.Application")

var oXL = new ActiveXObject("Excel.Application"); //报错
var oWB = oXL.Workbooks.Add();
var oSheet = oWB.ActiveSheet;oSheet.Rows(1).Font.Size=14;oSheet.Rows(1).Font.Name="黑体";oSheet.Columns.AutoFit;


解决方法:IE安全级别降低

你可能感兴趣的:(Excel,IE)