ntko execl操作[通俗易懂]

ntko execl操作[通俗易懂]

大家好,又见面了,我是你们的朋友全栈君。如果您正在找激活码,请点击查看最新教程,关注关注公众号 “全栈程序员社区” 获取激活教程,可能之前旧版本教程已经失效.最新Idea2022.1教程亲测有效,一键激活。

Jetbrains全家桶1年46,售后保障稳定

<OBJECT id=TANGER_OCX codeBase=”http://www.ntko.com/control/officecontrol/OfficeControl.cab#Version=5.0.2.5″ classid=clsid:A39F1330-3322-4a1d-9BF0-0BA2BB90E970 width=”100%” height=”100%”><PARAM NAME=”_ExtentX” VALUE=”19923″><PARAM NAME=”_ExtentY” VALUE=”12700″><PARAM NAME=”BorderColor” VALUE=”14402205″><PARAM NAME=”BackColor” VALUE=”-2147483643″><PARAM NAME=”ForeColor” VALUE=”-2147483640″><PARAM NAME=”TitlebarColor” VALUE=”42768″><PARAM NAME=”TitlebarTextColor” VALUE=”0″><PARAM NAME=”BorderStyle” VALUE=”1″><PARAM NAME=”Titlebar” VALUE=”0″><PARAM NAME=”Toolbars” VALUE=”0″><PARAM NAME=”Caption” VALUE=”欢迎使用!”><PARAM NAME=”IsShowToolMenu” VALUE=”1″><PARAM NAME=”IsNoCopy” VALUE=”0″><PARAM NAME=”IsHiddenOpenURL” VALUE=”0″><PARAM NAME=”MaxUploadSize” VALUE=”0″><PARAM NAME=”NetworkBufferSize” VALUE=”0″><PARAM NAME=”Menubar” VALUE=”1″><PARAM NAME=”Statusbar” VALUE=”1″><PARAM NAME=”FileNew” VALUE=”-1″><PARAM NAME=”FileOpen” VALUE=”-1″><PARAM NAME=”FileClose” VALUE=”-1″><PARAM NAME=”FileSave” VALUE=”-1″><PARAM NAME=”FileSaveAs” VALUE=”-1″><PARAM NAME=”FilePrint” VALUE=”-1″><PARAM NAME=”FilePrintPreview” VALUE=”-1″><PARAM NAME=”FilePageSetup” VALUE=”-1″><PARAM NAME=”FileProperties” VALUE=”-1″><PARAM NAME=”IsStrictNoCopy” VALUE=”0″><PARAM NAME=”IsUseUTF8URL” VALUE=”1″><PARAM NAME=”MenubarColor” VALUE=”14402205″><PARAM NAME=”IsUseControlAgent” VALUE=”0″><PARAM NAME=”IsUseUTF8Data” VALUE=”0″><PARAM NAME=”IsSaveDocExtention” VALUE=”0″><PARAM NAME=”IsDirectConnect” VALUE=”0″><PARAM NAME=”SignCursorType” VALUE=”0″><PARAM NAME=”IsResetToolbarsOnOpen” VALUE=”0″><PARAM NAME=”IsSaveDataIfHasVDS” VALUE=”0″><PARAM NAME=”MenuButtonStyle” VALUE=”7″><PARAM NAME=”MenuButtonColor” VALUE=”16180947″><PARAM NAME=”MenuButtonFrameColor” VALUE=”14924434″><PARAM NAME=”MenuBarStyle” VALUE=”3″><PARAM NAME=”IsGetPicOnlyOnHandSign” VALUE=”0″><PARAM NAME=”IsSecurityOptionsOpen” VALUE=”0″><PARAM NAME=”IsShowHelpMenu” VALUE=”0″><PARAM NAME=”IsShowInsertMenu” VALUE=”1″><PARAM NAME=”IsAutoDetectWebCharSet” VALUE=”0″><PARAM NAME=”WebCodePage” VALUE=”936″><PARAM NAME=”IsShowEditMenu” VALUE=”1″><PARAM NAME=”IsShowFileErrorMsg” VALUE=”1″><PARAM NAME=”IsShowNetErrorMsg” VALUE=”1″><PARAM NAME=”ReceiveDataTimeOut” VALUE=”180″><PARAM NAME=”ConnectServerTimeOut” VALUE=”180″><PARAM NAME=”IsRemoveMacrosOnSave” VALUE=”1″><PARAM NAME=”IsForceCheckSecSignCertCRLOnline” VALUE=”0″><PARAM NAME=”IsAutoLockOnSecSign” VALUE=”0″><PARAM NAME=”IsAllowAddSignOnLockedDoc” VALUE=”0″><PARAM NAME=”DefaultOpenDocType” VALUE=”0″><PARAM NAME=”IsShowFullScreenButton” VALUE=”-1″><PARAM NAME=”IsEnableDoubleClickFSM” VALUE=”-1″><PARAM NAME=”IsExcelAutoCalIncludeHidden” VALUE=”0″><PARAM NAME=”MaxNetworkBufferSize” VALUE=”8388608″><PARAM NAME=”IsEnableWordConverters” VALUE=”0″><PARAM NAME=”IsSave2007InnerFmt” VALUE=”0″><PARAM NAME=”EkeyType” VALUE=”1″><PARAM NAME=”CustomToolBar” VALUE=”0″><PARAM NAME=”IsOptForOpenSpeed” VALUE=”0″><PARAM NAME=”IsAllowEkeyOnlySignDemo” VALUE=”0″><PARAM NAME=”OptMSDocApp” VALUE=”0″><PARAM NAME=”IsUserDDE” VALUE=”0″><PARAM NAME=”IsEnableOtherPdfViewer” VALUE=”1″><PARAM NAME=”IsCheckEkey” VALUE=”0″><PARAM NAME=”MenuButtonDefaultColor” VALUE=”0″><PARAM NAME=”IsDebugNoDelfile” VALUE=”0″><PARAM NAME=”IsDebugLogDelfile” VALUE=”0″><PARAM NAME=”IsShowDocStatusInfo” VALUE=”1″><PARAM NAME=”IsFastSaveHandSign2″ VALUE=”0″><PARAM NAME=”IsSetShowFieldsValue” VALUE=”0″><PARAM NAME=”IsSetIEUploadFileContainLocalDir” VALUE=”1″><PARAM NAME=”IsSetSvrSignBelowText” VALUE=”0″><PARAM NAME=”IsUseOfficeConvertDocToPDF” VALUE=”0″><PARAM NAME=”MultiSecSignMarginSize” VALUE=”5″><PARAM NAME=”UseSignPartProtectDoc” VALUE=”0″><PARAM NAME=”SetMultiSecSignPosition” VALUE=”-1″><PARAM NAME=”IsAddRandomOffsetForMultiSecSign” VALUE=”0″></OBJECT>

function setObject(myParam)

{

        var TANGER_OCX_OBJ = document.all(“TANGER_OCX”);  

        TANGER_OCX_OBJ.CreateNew(“Excel.Sheet”);//创建Sheet   

        TANGER_OCX_OBJ.SetSheetName(1, “NeededList”);//修改SheetName   

        TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A1”).ColumnWidth=50/8;

        TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“B1”).ColumnWidth=130/8;

        TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“C1”).ColumnWidth=200/8;

        TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“D1”).ColumnWidth=100/8;

        TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“E1”).ColumnWidth=100/8;

        TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“F1”).ColumnWidth=430/8; 

        TANGER_OCX_OBJ.ActiveDocument.Sheets(1).PageSetup.Orientation = 2;//默认横向打印

        

              var sSQL=”select * from PR_PM_NeededList where PR_PM_NeededListUID='”+myParam+”‘ “;       

              var jsonData = CXJLib.Runtime.Engine.RunSQLGetDataSet(sSQL);  

              if(jsonData != null && jsonData.length>0) 

              {  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A1:F2”).Font.Bold = true;//加粗 1行和2行都执行此样式    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A1:F2”).HorizontalAlignment = -4108;//水平居中 1行和2行都执行此样式    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A1:F2”).Borders.LineStyle = 1;//边框 1行和2行都执行此样式    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A1:F1”).MergeCells = true;//合并    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A1:F1”).Font.Size = 16;//字号    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A1”).Value = “NAMIBIAN POLICE”;//设置内容    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A2:F2”).MergeCells = true;    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A2”).Value = “Needed List”;    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A2:F2”).Font.Size = 14;//字号    

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A3:C3”).MergeCells = true;  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A3”).Value = “NEEDED NO:”+decodeURIComponent(jsonData[0].NeededNo);  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A4:C4”).MergeCells = true;  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A4”).Value = “DEPOT:”+decodeURIComponent(jsonData[0].Depot);  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“D3:F3”).MergeCells = true;  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“D3”).Value = “REQUEST DATE:”+decodeURIComponent(jsonData[0].ReqDate);  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“D4:F4”).MergeCells = true;  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“D4”).Value = “STORE:”+decodeURIComponent(jsonData[0].Store);  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A5:F5”).MergeCells = true;  

                     TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A5”).Value = “DESCRIPTION:”+decodeURIComponent(jsonData[0].Description);         

                      

                     sSQL=”select * from PR_PM_NeededListDetail where PR_PM_NeededListUID='”+myParam+”‘ “;       

                     jsonData = CXJLib.Runtime.Engine.RunSQLGetDataSet(sSQL);   

                     if(jsonData != null && jsonData.length>0)  

                     { 

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A6:F6”).HorizontalAlignment = -4108;//水平居中 1行和2行都执行此样式   

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A6”).Value = “LINE NO.”;   

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“B6”).Value = “ICN”;   

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“C6”).Value = “ITEM Description”;   

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“D6”).Value = “DOQ”;   

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“E6”).Value = “QTY”;   

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“F6”).Value = “Description”; 

                           var sumrow=6+jsonData.length; 

                           var rownum = 7; 

                           for(i=0;i<jsonData.length;i++){ 

                                  rownum+=i; 

                                  TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A”+rownum).Value = decodeURIComponent(jsonData[i].Child_Index);    

                                  TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“B”+rownum).Value = decodeURIComponent(jsonData[i].MaterialNo);    

                                  TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“C”+rownum).Value = decodeURIComponent(jsonData[i].MaterialDesc);    

                                  TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“D”+rownum).Value = decodeURIComponent(jsonData[i].MaterialDOQ);    

                                  TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“E”+rownum).Value = decodeURIComponent(jsonData[i].MaterialQty);    

                                  TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“F”+rownum).Value = decodeURIComponent(jsonData[i].Description); 

                           } 

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A6:F”+sumrow).Borders.LineStyle = 1;//边框 1行和2行都执行此样式   

                           TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A7:F”+sumrow).WrapText=true;

                     } 

              } 

             else 

             { 

                    TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Range(“A1”).Value = “No Data”;    

             }

             TANGER_OCX_OBJ.ActiveDocument.Sheets(1).Application.Quit();

}

  

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 举报,一经查实,本站将立刻删除。

发布者:全栈程序员-用户IM,转载请注明出处:http://www.javaforall.cn/234706.html原文链接:http://www.javaforall.cn

【正版授权,激活自己账号】: Jetbrains全家桶Ide使用,1年售后保障,每天仅需1毛

【官方授权 正版激活】: 官方授权 正版激活 支持Jetbrains家族下所有IDE 使用个人JB账号...

(0)


相关推荐

  • Eclipse使用新手教程

    Eclipse使用新手教程

    2021年11月24日
  • ADRC自抗扰控制自学笔记(包含simulink仿真)(转载)

    ADRC自抗扰控制自学笔记(包含simulink仿真)(转载)摘自:https://blog.csdn.net/zouxu634866/article/details/106287879#comments_12978720ADRC自抗扰控制自学笔记(包含simulink仿真)总被蚊子叮的小旭2020-05-2217:59:361856收藏28分类专栏:控制版权ADRC控制中包含三个主要的部分:跟踪微分器,非线性状态反馈(非线性组合),扩张观测器。ADRC特点:继承了经典PID控制器的精华,对被控对…

  • allegro16.6转pads9.5实战攻略

    allegro16.6转pads9.5实战攻略1)要建立两个用户变量(如已存在,不需要建立) 。AEX_BIN_ROOTD:\MentorGraphics\9.5PADS\SDD_HOME\translators\win32\bi

  • 初级算法学习步骤

    初级算法学习步骤前言零散整理一个多月终于整理完了。。。。这是一篇初级算法学习的步骤总结,或许可以帮助你怎么去接触算法阅读本文需要一定java语法基础和api文档查看基础,但算法其实看重的是思想而不是语言,所以都可以借鉴。本人大二,参加过蓝桥杯。一直没时间吧之前的总结整理出来,现在准备整理一下用java做算法的一些东西……学习了两个月左右算法,从啥都不会到小白再到算是初级……做一个总结,请高手多多指…

  • java旅游管理系统(带文档

    java旅游管理系统(带文档关注公众号,回复:java旅游管理系统,获取源码,百度云哦。不会安装,找公众号管理员

  • java 文件转inputstream_把文本转换成表格

    java 文件转inputstream_把文本转换成表格以下是一些将InputStream转换为FileJava示例手动将InputStream复制到FileOutputStreamApacheCommonsIO–FileUtils.copyInputStreamToFileJava1.7NIOFiles.copy1.FileOutputStream1.1我们必须将数据从InputStream手动复…

发表回复

您的电子邮箱地址不会被公开。

关注全栈程序员社区公众号