Thread View: comp.lang.basic.visual.misc
3 messages
3 total messages
Started by Gil Murray
Sun, 19 Nov 1995 00:00
Synchronising VB with a shelled Word Perfect macro
Author: Gil Murray
Date: Sun, 19 Nov 1995 00:00
Date: Sun, 19 Nov 1995 00:00
28 lines
1526 bytes
1526 bytes
Hi,
I'm trying to shell a Word Perfect macro from Visual Basic, then hold
VB back from further execution until the macro has completed:
X% = Shell("d:\office\wpwin\wpwin.exe /m-a:path.wcm",2)
Templatefile$ = "c:\windows\path.tmp" 'the macro will create this
Do Until FileExists(Templatefile$)
Loop
The last line of the short three line macro path.wcm does a
FileSave(Filename:" c:\windows\path.tmp"...) so theoretically the VB
loop should exit when it finds that path.tmp has been created.
However, the loop seems to "steal" the processor before the macro even
reaches its second line (Type: ?PathTemplate) and never returns
execution to the macro. Result, an infinite loop, because path.tmp is
never created!
I'm running VB 3.0 on Windows '95 with Word Perfect 6.1. I get the
same behaviour on Windows 3.11. I've also tried calling the macro via
DDEexecute - same problem.
Has anyone come across a workround for this?
Thanks,
Gil
Re: Synchronising VB with a shelled Word Perfect macro
Author: Jens Balchen Jr.
Date: Mon, 20 Nov 1995 00:00
Date: Mon, 20 Nov 1995 00:00
22 lines
1194 bytes
1194 bytes
In article <48o83b$8e5@soap.news.pipex.net>, gil@dial.pipex.com (Gil
Murray) wrote:
>I'm trying to shell a Word Perfect macro from Visual Basic, then hold
>VB back from further execution until the macro has completed:
>X% = Shell("d:\office\wpwin\wpwin.exe /m-a:path.wcm",2)
>Templatefile$ = "c:\windows\path.tmp" 'the macro will create this
> Do Until FileExists(Templatefile$)
DoEvents
> Loop
Jens
* Everything I said are the opinions of someone else. *
* I just cut-and-pasted. *
Jens Balchen jr.
balchen@oslonett.no
P.O.Box 6052
N-4602 Kristiansand
Re: Synchronising VB with a shelled Word Perfect macro
Author: Gil Murray
Date: Thu, 23 Nov 1995 00:00
Date: Thu, 23 Nov 1995 00:00
19 lines
985 bytes
985 bytes
Yes!
Thank you Jens, and also Henk Op den Brouw who gave me the same advice
by e-mail.
Cheers,
Gil
balchen@oslonett.no (Jens Balchen Jr.) wrote:
<snip>
>>X% = Shell("d:\office\wpwin\wpwin.exe /m-a:path.wcm",2)
>>Templatefile$ = "c:\windows\path.tmp" 'the macro will create this
>> Do Until FileExists(Templatefile$)
>DoEvents
>> Loop
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads