AX_SysExcel
void KTL_CPeng_ImportCustStamp()
{
str file;
FileNameFilter filter = ["@SYS57521",'*.xlsx', "@SYS101541",'*.xls'];
COMVariant COMVariant1;
SysExcelApplication app;
SysExcelWorkbooks Workbooks;
SysExcelWorkbook Workbook;
SysExcelWorksheets Worksheets;
SysExcelWorksheet Worksheet;
SysExcelCells Cells;
SysExcelCell RCell1, RCell2, RCell3,RCell4,RCell5,RCell6,RCell7, RCell8;
int i, j;
#excel
;
try
{
ttsbegin;
file = Winapi::getOpenFileName(, filter, '', "Open Excel Files");
app = SysExcelApplication::construct();
Workbooks = app.Workbooks();
COMVariant1 = new COMVariant();
COMVariant1.bStr(file);
Workbook = Workbooks.Add(COMVariant1);
Worksheets = Workbook.worksheets();
Worksheet = Worksheets.itemFromName("sheet1");
//Worksheet = worksheets.itemFromNum(1);
Cells = Worksheet.Cells();
i = ; // first line is a title, start line 2
RCell1 = Cells.Item(i, );
RCell2 = Cells.Item(i, );
RCell3 = Cells.Item(i, );
RCell4 = Cells.Item(i, );
RCell5 = Cells.Item(i, );
RCell6 = Cells.Item(i, );
RCell7 = Cells.Item(i, );
RCell8 = Cells.Item(i, );
while (RCell1.value().bStr() != "")
{
print Cells.item(i, ).value().bStr();
// add code
i++;
RCell1 = Cells.item(i, );
RCell2 = Cells.Item(i, );
RCell3 = Cells.Item(i, );
RCell4 = Cells.Item(i, );
RCell5 = Cells.Item(i, );
RCell6 = Cells.Item(i, );
RCell7 = Cells.Item(i, );
RCell8 = Cells.Item(i, );
}
ttscommit;
info(strfmt("%1 %2 %3", "Update Complete", i-, curext()));
}
catch
{
info("Nothing Uploaded");
}
}
AX_SysExcel的更多相关文章
随机推荐
- Android Gradle 依赖方式
Android Gradle 依赖方式有以下6种: Compile compile是对所有的build type以及favlors都会参与编译并且打包到最终的apk文件中. Provided Prov ...
- Shiro+CAS
参考链接: CAS实现单点登录SSO执行原理探究:http://blog.csdn.net/javaloveiphone/article/details/52439613 单点登录CAS技术概述:ht ...
- Vue keep-alive的总结
1.基本用法 vue2.0提供了一个keep-alive组件用来缓存组件,避免多次加载相应的组件,减少性能消耗. <keep-alive> <component> <!- ...
- spring boot 之 错误:SpelEvaluationException: EL1008E: Property or field 'timestamp' cannot be found on object of type 'java.util.HashMap'
这个错误我也见过很多次了,今天终于理解了其出现的原因. 错误是这样的: 2017-11-23 18:05:39.504 ERROR 4092 --- [nio-8080-exec-3] o.a.c.c ...
- leetcode461
public class Solution { public int HammingDistance(int x, int y) { ]; ]; ; ; do { aryA[i] = x % ;//将 ...
- Python面向对象编程(上)
Python不仅支持面向过程编程,同时也支持面向对象编程.面向工程就是分析解决问题所需的步骤,然后用函数把这些步骤逐一实现,使用的时候再一个个调用函数就可以.面向对象则是把解决的问题按照一定规则划分为 ...
- SVN中英文菜单对照
TortoiseSVN英文版菜单中文翻译01.SVN Checkout(SVN取出) 点击SVN Checkout,弹出检出提示框,在URL of repository输入框中输入服务器仓库地址,在C ...
- zabbix监控内存占前3位的进程信息
一.编写shell脚本 ps aux|sort -k4nr|head -3|awk 'split($11,a,"/"){print $4","a[length( ...
- ubuntu下搭建svn服务器
[ubuntu下搭建svn服务器] 1.创建目录 mkdir ~/svn/repository/ 2.创建仓库 svnadmin create repository 3.进入 repository/c ...
- cdnbest里如何查看网站是否被缓存
比如开启了强制缓存,如何查看缓存是否生效 本例以firefox浏览器查看,先打开浏览器,按下F12, 然后在浏览器是输入网址访问 如下图响应头里的 x-cache显示 Miss from 就是没有缓 ...