WordBasic Edit auto text command

Z

zirac

I'm currently updating an old template. When I open the template and double
click anywhere on the document, a dialog box will open and let me select from
the checkbox. After I click OK, A line or lines will be inserted on the
letter saying that we are asking for the selected documents. I now want to
change the test on the lines but I can't find it on the codes. Are they
saved somewhere?

Also, when I try to print this letter using a macro so it will print 1 in
letterhead and 1 in plain it's not printing correclty. It's printing in 3
different pages. But it works fine if I use the normal print button.

See part of the codes below:

WordBasic.BeginDialog 400, 240, "Details"
WordBasic.GroupBox 21, 2, 280, 200, "Select which documents are required"
WordBasic.CheckBox 56, 16, 200, 18, "Mortgage certificate:", "Mort"
WordBasic.CheckBox 56, 38, 200, 18, "Loan certificate:", "Loan"
WordBasic.OKButton 310, 6, 88, 21
WordBasic.CancelButton 310, 30, 88, 21
WordBasic.EndDialog

Dim Lettera As Object: Set Lettera = WordBasic.CurValues.UserDialog
WordBasic.ViewPage
WordBasic.DisableInput 1
n = WordBasic.Dialog.UserDialog(Lettera)
WordBasic.DisableInput 0

Mort = Lettera.Mort
Loan = Lettera.Loan

WordBasic.ScreenUpdating 0
WordBasic.ToolsUnprotectDocument DocumentPassword:="test"
WordBasic.WW7_EditGoTo Destination:="s2"
If Mort = 1 Then
WordBasic.InsertPara
WordBasic.InsertPara
WordBasic.WW7_EditAutoText Name:="mortgage", InsertAs:=1, Insert:=1
End If
If Loan = 1 Then
WordBasic.InsertPara
WordBasic.InsertPara
WordBasic.WW7_EditAutoText Name:="Loan", InsertAs:=1, Insert:=1
End If
 
C

Cindy M.

Hi =?Utf-8?B?emlyYWM=?=,
I'm currently updating an old template. When I open the template and double
click anywhere on the document, a dialog box will open and let me select from
the checkbox. After I click OK, A line or lines will be inserted on the
letter saying that we are asking for the selected documents. I now want to
change the test on the lines but I can't find it on the codes. Are they
saved somewhere?
It's really not possible for anyone who doesn't have the document and the code
to trouble-shoot everything at this remove, especially if you don't have any
WordBasic background at all.

You may have to hire someone who does have the background, or who can analyze
and rewrite the tool in VBA. At some point, the WordBasic is just going to stop
working...

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or reply
in the newsgroup and not by e-mail :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top