注册 登录
编程论坛 VFP论坛

VFP操作Word文档的学习资料

预言家 发布于 2020-10-06 09:38, 1751 次点击
我想学习VFP操作WORD文档,每次都是从网上搜很久才能找到想要的功能,有没有什么学习资料、方法可以主动学习的呢?   
2 回复
#2
预言家2020-10-06 09:41
以下代码是设置Word页码的。注释掉的两行是VBA的宏程序代码,设置页码不关联上一节,如何改成VFP的代码?
WITH  JccgWord
   .ActiveWindow.ActivePane.View.SeekView=10
   .Selection.Sections(1).Headers(1).PageNumbers.Add(5,.t.)
   .Selection.Font.Size = 10.5  &&指定字号,9为小五号,10.5为五号,12为小四号
   .Selection.Font.Name = "宋体"  &&设置字体
   .Selection.Fields.Add(JccgWord.Selection.Range, -1,"Page \* MergeFormat",.f.)
   .Selection.ParagraphFormat.Alignment = 1  &&页脚居中
*!*       .Selection.ParagraphFormat.RestartNumberingAtSection =.T.
*!*       .Selection.ParagraphFormat.StartingNumber = 1
   .ActiveWindow.ActivePane.View.SeekView=0
ENDWITH
#3
吹水佬2020-10-06 11:45
参考资料:https://docs.
1