我用VC++能实现word的打开和关闭,但是翻译不了word宏的文字替换代码
请教高手这样把这段代码翻译成vc++语句 谢谢
请教高手这样把这段代码翻译成vc++语句 谢谢
解决方案 »
- VC2010有什么好用的数据表格控件吗
- 求会speech SDK的大哥大姐帮帮小弟
- VC调用其他程序的传递参数问题
- 急求 如何侦测显示器的亮度等设置被修改的事件
- afx.inl 的问题,debug assertion failed! line 122!要命编译的过程中没问题,运行时报错,不知道怎样调试??
- 请教:打印完位图后程序崩溃 怎么解决?
- 关于mfc的列表框
- Unicode乱码问题,新手用vs2008,求救啊~~
- 谁答出来了我以身相许...(没有分数!!!)
- 紧急!如何将一个LPCTSTR的内容赋值给一个CString对象?
- 在自己定义的框加CMyFrameWnd 中创建视图(自己定义视图)问题.
- 基于Web的计算机等级考试报名系统
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = "阿苏大发苏大发"
.Replacement.Text = "{m_stuio}"
.Forward = True
.Wrap = wdFindAsk
.Format = False
.MatchCase = False
.MatchWholeWord = False
.MatchByte = True
.CorrectHangulEndings = False
.MatchAllWordForms = False
.MatchSoundsLike = False
.MatchWildcards = False
.MatchFuzzy = False
End With
With Selection
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseStart
Else
.Collapse Direction:=wdCollapseEnd
End If
.Find.Execute Replace:=wdReplaceOne
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseEnd
Else
.Collapse Direction:=wdCollapseStart
End If
.Find.Execute
End With
With Selection
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseStart
Else
.Collapse Direction:=wdCollapseEnd
End If
.Find.Execute Replace:=wdReplaceOne
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseEnd
Else
.Collapse Direction:=wdCollapseStart
End If
.Find.Execute
End With
With Selection
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseStart
Else
.Collapse Direction:=wdCollapseEnd
End If
.Find.Execute Replace:=wdReplaceOne
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseEnd
Else
.Collapse Direction:=wdCollapseStart
End If
.Find.Execute
End With
With Selection
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseStart
Else
.Collapse Direction:=wdCollapseEnd
End If
.Find.Execute Replace:=wdReplaceOne
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseEnd
Else
.Collapse Direction:=wdCollapseStart
End If
.Find.Execute
End With
With Selection
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseStart
Else
.Collapse Direction:=wdCollapseEnd
End If
.Find.Execute Replace:=wdReplaceOne
If .Find.Forward = True Then
.Collapse Direction:=wdCollapseEnd
Else
.Collapse Direction:=wdCollapseStart
End If
.Find.Execute
End With
Selection.Find.Execute Replace:=wdReplaceAll
End Sub
support.microsoft.com/support/KB/Articles/Q194/9/06.asp
http://www.kayodeok.btinternet.co.uk/favorites/kbofficewordhowto.htm
use vtmissing for optional parameters
http://support.microsoft.com/kb/295692
还有Find的属性设置对应msword9.h中的那个函数
感激!!!!!!
邮箱:
[email protected]
邮箱:[email protected]