>Bob,
>
>THanks for the code below. It works except for one little thing. When I click cancel on the print dialog screen I get the following error: OLE Error Code 0x80040100: Trying to revoke a drop target that has not been registered.
>
>It sounds to me like a drag and drop issue. Have you ever come across this message?
Yea... I think I saw that message once... Not really sure what it was. Perhaps somehow the control is seeing the mouse click the cancel button above it.
>
>any ideas, thanks
You could try to disable the olecontrol1 during the print process, or lock the screen... I don't know, figured I got you 90% of the way. <g> Or, you could turn OLEDragDrop off on the browser... not sure, let me know if you come up with something.
BOb
>
>Jim
>
>>>It's an ActiveX control
>>>
>>
>>Ok Jim... the heck with that VB stuff... now that I know the problem, I can solve it the simple VFP way... Here is the code to put in your command click:
>>
>>
>>this.Enabled = .f.
>>Do While ThisForm.OleControl1.Busy
>> DoEvents()
>>enddo
>>ThisForm.Olecontrol1.ExecWB( 6, 0 )
>>this.Enabled = .t.
>>
>>
>>BOb