pb word 文字个数统计

时间:2018-11-10 03:58:39
【文件属性】:
文件名称:pb word 文字个数统计
文件大小:11KB
文件格式:RAR
更新时间:2018-11-10 03:58:39
pb word total 主要代码 string ls_filename, ls_path integer li_value oleobject ole_word long ll_cnt ole_word = create oleobject li_value = ole_word.connecttonewobject("word.application") if li_value <> 0 then messagebox("info", "连接word失败,请检查") return -1 end if if GetFileOpenName("选择文件", ls_filename, ls_path, "Word Files (*.doc), *.doc, All Files(*.*), *.*") <> 1 then ole_word.quit() ole_word.disconnectobject() destroy ole_word return 1 end if if len(trim(ls_filename)) <= 0 then return -1 else ole_word.Documents.open(ls_filename) ll_cnt = ole_word.ActiveDocument.Content.End messagebox('Word total:', ll_cnt) ole_word.quit() ole_word.disconnectobject() destroy ole_word end if
【文件预览】:
ptest.pbl
ptest.pbt

网友评论