This is a multi-part message in MIME format.

------=_NextPart_000_0008_01C8901F.A7DC07A0
Content-Type: text/plain;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

Hi All

vfp9, SP1

I wanted to create a simple Word doc and then let the user edit; all =
this works fine

I also wanted vfp to wait until user closed Word
Instead of wait state or using wsh, I thought I would use bindevent and =
prevent return to vfp until Word closed (or at least document closed)

following Doub Hennig article =
http://msdn2.microsoft.com/en-us/library/ms947678.aspx
I created a link like: bindevent(_vfp.hWnd, WM_ACTIVATE, oApp, =
"WindowsEvents")
the bindevent works fine (it correctly gets to oApp.WindowsEvents)
however, I have 2 problems

1. if I return BROADCAST_QUERY_DENY for vfp Activate in WindowsEvents =
(not calling WindowProc), it does not stop vfp from coming forward

2. the 2nd time I click on vfp top bar (not in screen), it maximizes the =
window (like it thinks I double clicked even if some time has passed)

anyone know what I am doing wrong ?

al


------=_NextPart_000_0008_01C8901F.A7DC07A0
Content-Type: text/html;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dwindows-1252">
<META content=3D"MSHTML 6.00.2900.3268" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV><FONT face=3DArial size=3D2>Hi All</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>vfp9, SP1</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I wanted to create a simple Word doc =
and then let=20
the user edit; all this works fine</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I also wanted vfp to wait until user =
closed=20
Word</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Instead of wait state or using wsh, I =
thought I=20
would use bindevent and prevent return to vfp until Word closed (or at =
least=20
document closed)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>following Doub Hennig article =
</FONT><FONT=20
face=3DArial size=3D2><A=20
href=3D"http://msdn2.microsoft.com/en-us/library/ms947678.aspx">http://ms=
dn2.microsoft.com/en-us/library/ms947678.aspx</A></FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I created a link like:&nbsp; <FONT=20
face=3D"Courier New" color=3D#0000ff size=3D2>bindevent</FONT><FONT =
face=3D"Courier New"=20
size=3D2>(</FONT><FONT face=3D"Courier New" color=3D#0000ff =
size=3D2>_vfp</FONT><FONT=20
face=3D"Courier New" size=3D2>.</FONT><FONT face=3D"Courier New" =
color=3D#0000ff=20
size=3D2>hWnd</FONT><FONT face=3D"Courier New" size=3D2>, WM_ACTIVATE, =
</FONT><FONT=20
face=3D"Courier New" color=3D#0000ff size=3D2>oApp</FONT><FONT =
face=3D"Courier New"=20
size=3D2>, "WindowsEvents")</FONT></FONT></DIV>
<DIV><FONT face=3DArial size=3D2>the bindevent works fine (it correctly =
gets to=20
oApp.WindowsEvents)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>however, I have 2 problems</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>1. if I return BROADCAST_QUERY_DENY for =
vfp=20
Activate in WindowsEvents (not calling WindowProc), it does not stop vfp =
from=20
coming forward</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>2. the 2nd time I click on vfp top bar =
(not in=20
screen), it maximizes the window (like it thinks I double clicked even =
if some=20
time has passed)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>anyone know what I am doing wrong =
?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>al</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2></FONT><FONT face=3DArial =
size=3D2></FONT><FONT=20
face=3DArial size=3D2></FONT>&nbsp;</DIV></BODY></HTML>

------=_NextPart_000_0008_01C8901F.A7DC07A0--

RE: bindevent problem by MichelRoy

MichelRoy
Fri Mar 28 07:14:01 CDT 2008

What is _VFP.Autoyield set to?

"Al Marino" wrote:

> Hi All
>
> vfp9, SP1
>
> I wanted to create a simple Word doc and then let the user edit; all this works fine
>
> I also wanted vfp to wait until user closed Word
> Instead of wait state or using wsh, I thought I would use bindevent and prevent return to vfp until Word closed (or at least document closed)
>
> following Doub Hennig article http://msdn2.microsoft.com/en-us/library/ms947678.aspx
> I created a link like: bindevent(_vfp.hWnd, WM_ACTIVATE, oApp, "WindowsEvents")
> the bindevent works fine (it correctly gets to oApp.WindowsEvents)
> however, I have 2 problems
>
> 1. if I return BROADCAST_QUERY_DENY for vfp Activate in WindowsEvents (not calling WindowProc), it does not stop vfp from coming forward
>
> 2. the 2nd time I click on vfp top bar (not in screen), it maximizes the window (like it thinks I double clicked even if some time has passed)
>
> anyone know what I am doing wrong ?
>
> al
>
>

Re: bindevent problem by Al

Al
Fri Mar 28 08:45:38 CDT 2008

left at default .T.
as I understand it, setting to .F. would prevend user
initialted events in vfp
I am trying to prevent vfp from being activated after
calling Word

al


"Michel Roy" <MichelRoy@discussions.microsoft.com> wrote in
message
news:CEDDA1B5-06AC-411A-97CF-E367D3BA1568@microsoft.com...
> What is _VFP.Autoyield set to?
>
> "Al Marino" wrote:
>
>> Hi All
>>
>> vfp9, SP1
>>
>> I wanted to create a simple Word doc and then let the
>> user edit; all this works fine
>>
>> I also wanted vfp to wait until user closed Word
>> Instead of wait state or using wsh, I thought I would use
>> bindevent and prevent return to vfp until Word closed (or
>> at least document closed)
>>
>> following Doub Hennig article
>> http://msdn2.microsoft.com/en-us/library/ms947678.aspx
>> I created a link like: bindevent(_vfp.hWnd, WM_ACTIVATE,
>> oApp, "WindowsEvents")
>> the bindevent works fine (it correctly gets to
>> oApp.WindowsEvents)
>> however, I have 2 problems
>>
>> 1. if I return BROADCAST_QUERY_DENY for vfp Activate in
>> WindowsEvents (not calling WindowProc), it does not stop
>> vfp from coming forward
>>
>> 2. the 2nd time I click on vfp top bar (not in screen),
>> it maximizes the window (like it thinks I double clicked
>> even if some time has passed)
>>
>> anyone know what I am doing wrong ?
>>
>> al
>>
>>



Re: bindevent problem by Anders

Anders
Fri Mar 28 15:08:29 CDT 2008

This is a multi-part message in MIME format.

------=_NextPart_000_0148_01C89117.DF590E50
Content-Type: text/plain;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

If you use the EventHandler function to couple a VFP class to events in =
Word you can let the Quit event in Word close your VFp app.'
You can let VFP create this class, by first opening Word in thr Object =
Browser, then dragging the appropriate Interface node from the Object =
Browser to an program editing window in VFP .=20
-Anders=20
=20
"Al Marino" <almarino_AT_intelliform.net> wrote in message =
news:uR0ZwEEkIHA.4396@TK2MSFTNGP04.phx.gbl...
Hi All

vfp9, SP1

I wanted to create a simple Word doc and then let the user edit; all =
this works fine

I also wanted vfp to wait until user closed Word
Instead of wait state or using wsh, I thought I would use bindevent =
and prevent return to vfp until Word closed (or at least document =
closed)

following Doub Hennig article =
http://msdn2.microsoft.com/en-us/library/ms947678.aspx
I created a link like: bindevent(_vfp.hWnd, WM_ACTIVATE, oApp, =
"WindowsEvents")
the bindevent works fine (it correctly gets to oApp.WindowsEvents)
however, I have 2 problems

1. if I return BROADCAST_QUERY_DENY for vfp Activate in WindowsEvents =
(not calling WindowProc), it does not stop vfp from coming forward

2. the 2nd time I click on vfp top bar (not in screen), it maximizes =
the window (like it thinks I double clicked even if some time has =
passed)

anyone know what I am doing wrong ?

al


------=_NextPart_000_0148_01C89117.DF590E50
Content-Type: text/html;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dwindows-1252">
<META content=3D"MSHTML 6.00.6000.16608" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>If you use the EventHandler function to =
couple a=20
VFP class to&nbsp;events in&nbsp;Word you can let the Quit event =
in&nbsp;Word=20
close your VFp app.'</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>You can let VFP create this =
class,&nbsp;by first=20
opening Word in thr Object Browser, then&nbsp;dragging the appropriate =
Interface=20
node from the Object Browser to an program editing window in VFP=20
.&nbsp;</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>-Anders </FONT></DIV>
<DIV>&nbsp;</DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Al Marino" &lt;almarino_AT_intelliform.net&gt; wrote in message =
<A=20
=
href=3D"news:uR0ZwEEkIHA.4396@TK2MSFTNGP04.phx.gbl">news:uR0ZwEEkIHA.4396=
@TK2MSFTNGP04.phx.gbl</A>...</DIV>
<DIV><FONT face=3DArial size=3D2>Hi All</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>vfp9, SP1</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I wanted to create a simple Word doc =
and then let=20
the user edit; all this works fine</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I also wanted vfp to wait until user =
closed=20
Word</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Instead of wait state or using wsh, I =
thought I=20
would use bindevent and prevent return to vfp until Word closed (or at =
least=20
document closed)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>following Doub Hennig article =
</FONT><FONT=20
face=3DArial size=3D2><A=20
=
href=3D"http://msdn2.microsoft.com/en-us/library/ms947678.aspx">http://ms=
dn2.microsoft.com/en-us/library/ms947678.aspx</A></FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I created a link like:&nbsp; <FONT=20
face=3D"Courier New" color=3D#0000ff size=3D2>bindevent</FONT><FONT=20
face=3D"Courier New" size=3D2>(</FONT><FONT face=3D"Courier New" =
color=3D#0000ff=20
size=3D2>_vfp</FONT><FONT face=3D"Courier New" size=3D2>.</FONT><FONT=20
face=3D"Courier New" color=3D#0000ff size=3D2>hWnd</FONT><FONT =
face=3D"Courier New"=20
size=3D2>, WM_ACTIVATE, </FONT><FONT face=3D"Courier New" =
color=3D#0000ff=20
size=3D2>oApp</FONT><FONT face=3D"Courier New" size=3D2>,=20
"WindowsEvents")</FONT></FONT></DIV>
<DIV><FONT face=3DArial size=3D2>the bindevent works fine (it =
correctly gets to=20
oApp.WindowsEvents)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>however, I have 2 =
problems</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>1. if I return BROADCAST_QUERY_DENY =
for vfp=20
Activate in WindowsEvents (not calling WindowProc), it does not stop =
vfp from=20
coming forward</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>2. the 2nd time I click on vfp top =
bar (not in=20
screen), it maximizes the window (like it thinks I double clicked even =
if some=20
time has passed)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>anyone know what I am doing wrong =
?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>al</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2></FONT><FONT face=3DArial =
size=3D2></FONT><FONT=20
face=3DArial size=3D2></FONT>&nbsp;</DIV></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_0148_01C89117.DF590E50--


Re: bindevent problem by Al

Al
Tue Apr 01 07:58:46 CDT 2008

This is a multi-part message in MIME format.

------=_NextPart_000_002F_01C893D6.97F920B0
Content-Type: text/plain;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

thanks for reply,

perhaps I was not clear
I merely want to prevent vfp from receiving focus while the document in =
Word is open
thus I do not want to trap an event in Word (they may be switching to =
something else)
I wanted to trap the Activate of vfp and not allow

al


"Anders Altberg" <anders.altberg> wrote in message =
news:e9z2E%23QkIHA.4664@TK2MSFTNGP03.phx.gbl...
If you use the EventHandler function to couple a VFP class to events =
in Word you can let the Quit event in Word close your VFp app.'
You can let VFP create this class, by first opening Word in thr Object =
Browser, then dragging the appropriate Interface node from the Object =
Browser to an program editing window in VFP .=20
-Anders=20

"Al Marino" <almarino_AT_intelliform.net> wrote in message =
news:uR0ZwEEkIHA.4396@TK2MSFTNGP04.phx.gbl...
Hi All

vfp9, SP1

I wanted to create a simple Word doc and then let the user edit; all =
this works fine

I also wanted vfp to wait until user closed Word
Instead of wait state or using wsh, I thought I would use bindevent =
and prevent return to vfp until Word closed (or at least document =
closed)

following Doub Hennig article =
http://msdn2.microsoft.com/en-us/library/ms947678.aspx
I created a link like: bindevent(_vfp.hWnd, WM_ACTIVATE, oApp, =
"WindowsEvents")
the bindevent works fine (it correctly gets to oApp.WindowsEvents)
however, I have 2 problems

1. if I return BROADCAST_QUERY_DENY for vfp Activate in =
WindowsEvents (not calling WindowProc), it does not stop vfp from coming =
forward

2. the 2nd time I click on vfp top bar (not in screen), it maximizes =
the window (like it thinks I double clicked even if some time has =
passed)

anyone know what I am doing wrong ?

al


------=_NextPart_000_002F_01C893D6.97F920B0
Content-Type: text/html;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dwindows-1252">
<META content=3D"MSHTML 6.00.2900.3268" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>thanks for reply,<BR><BR>perhaps I was =
not=20
clear<BR>I merely want to prevent vfp from receiving focus while the =
document in=20
Word is open<BR>thus I do not want to trap an event in Word (they may be =

switching to something else)<BR>I wanted to trap the Activate of vfp and =
not=20
allow<BR><BR>al</FONT><BR><BR></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Anders Altberg" &lt;anders.altberg&gt; wrote in message <A=20
=
href=3D"news:e9z2E%23QkIHA.4664@TK2MSFTNGP03.phx.gbl">news:e9z2E%23QkIHA.=
4664@TK2MSFTNGP03.phx.gbl</A>...</DIV>
<DIV><FONT face=3DArial size=3D2>If you use the EventHandler function =
to couple a=20
VFP class to&nbsp;events in&nbsp;Word you can let the Quit event =
in&nbsp;Word=20
close your VFp app.'</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>You can let VFP create this =
class,&nbsp;by first=20
opening Word in thr Object Browser, then&nbsp;dragging the appropriate =

Interface node from the Object Browser to an program editing window in =
VFP=20
.&nbsp;</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>-Anders </FONT></DIV>
<DIV>&nbsp;</DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Al Marino" &lt;almarino_AT_intelliform.net&gt; wrote in =
message <A=20
=
href=3D"news:uR0ZwEEkIHA.4396@TK2MSFTNGP04.phx.gbl">news:uR0ZwEEkIHA.4396=
@TK2MSFTNGP04.phx.gbl</A>...</DIV>
<DIV><FONT face=3DArial size=3D2>Hi All</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>vfp9, SP1</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I wanted to create a simple Word =
doc and then=20
let the user edit; all this works fine</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I also wanted vfp to wait until =
user closed=20
Word</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Instead of wait state or using wsh, =
I thought I=20
would use bindevent and prevent return to vfp until Word closed (or =
at least=20
document closed)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>following Doub Hennig article =
</FONT><FONT=20
face=3DArial size=3D2><A=20
=
href=3D"http://msdn2.microsoft.com/en-us/library/ms947678.aspx">http://ms=
dn2.microsoft.com/en-us/library/ms947678.aspx</A></FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I created a link like:&nbsp; <FONT=20
face=3D"Courier New" color=3D#0000ff size=3D2>bindevent</FONT><FONT=20
face=3D"Courier New" size=3D2>(</FONT><FONT face=3D"Courier New" =
color=3D#0000ff=20
size=3D2>_vfp</FONT><FONT face=3D"Courier New" =
size=3D2>.</FONT><FONT=20
face=3D"Courier New" color=3D#0000ff size=3D2>hWnd</FONT><FONT =
face=3D"Courier New"=20
size=3D2>, WM_ACTIVATE, </FONT><FONT face=3D"Courier New" =
color=3D#0000ff=20
size=3D2>oApp</FONT><FONT face=3D"Courier New" size=3D2>,=20
"WindowsEvents")</FONT></FONT></DIV>
<DIV><FONT face=3DArial size=3D2>the bindevent works fine (it =
correctly gets to=20
oApp.WindowsEvents)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>however, I have 2 =
problems</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>1. if I return BROADCAST_QUERY_DENY =
for vfp=20
Activate in WindowsEvents (not calling WindowProc), it does not stop =
vfp=20
from coming forward</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>2. the 2nd time I click on vfp top =
bar (not in=20
screen), it maximizes the window (like it thinks I double clicked =
even if=20
some time has passed)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>anyone know what I am doing wrong=20
?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>al</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2></FONT><FONT face=3DArial =
size=3D2></FONT><FONT=20
face=3DArial =
size=3D2></FONT>&nbsp;</DIV></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_002F_01C893D6.97F920B0--