Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
WordPerfect Merge
Message
 
 
À
21/03/2003 15:38:13
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00768649
Message ID:
00768847
Vues:
30
Randy,

If type library isn't on the list, you can use Browse button to locate it.

>No you cant. The Corel - WordPerfect 9 type library does not show up in the list in Fox's object browser. But your answer was useful, as I hunted down the OLE/COM Object Viewer from VS 6.0 and used it to obtain the enum values.
>
>Leading to a dead end. There was no command to specify the ODBC path, so the user kept getting pestered for the path, and this was unacceptable. This particular merge was for only one data record, so the following kludge got me home. It is easily adapted for multi record sets. We call WP and instruct it to create its own format data file from our data.
>oWP = CreateObject("WordPerfect.PerfectScript")
>With oWP
>  .AppMaximize
>  .FileNew()
>  fnstr=""
>  for z=1 to fcount()
>    fnstr=fnstr+field(z)
>    if z<fcount()
>      fnstr=fnstr+(";")
>    endif
>  next
>  .MergeCode(78,fnstr) && Field Names
>  for z=1 to fcount()
>    fmac=field(z)
>    fval=transform(&fmac)
>    .type(fval)
>    if z<fcount()
>      .MergeCode(10) && EndField
>    else
>      .MergeCode(13) && EndRecord
>    endif
>  next
>  .FileSave(addbs(datapath)+"plus4a.dat",4,1)
>  .CloseNoSave(0)
>  .MergeRun(2,addbs(datapath)+"plus4a.wpd",2,addbs(datapath)+"plus4a.dat",1)
>  .PosDocTop()
>  wc=messagebox("Choose OK when done with WordPerfect")
>  .Quit
>endwith
>oWP=""
>release oWP
--sb--
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform