ensure that Outlook does not respond to mouse events and keyboard

Add-in Express™ Support Service
That's what is more important than anything else

ensure that Outlook does not respond to mouse events and keyboard
 
Stan




Posts: 13
Joined: 2011-06-09
Hi,

since any event, I would like to open a dialog box that is pseudo modal, meaning that every mouse click or key press is inhibited in Outlook during treatment.
The dialog is designed to display information and allow the cancellation of work.
The code below works for a TForm, but not in a TadxCOMAddInModule.
How do the equivalent of Enabled: = false in the Outlook application?


procedure TForm1.Button1Click(Sender: TObject);
var
    i : integer;
begin

    FSynchro.bStoped := false; // TFSynchro = class(TForm)
    FSynchro.Visible := true;
    FSynchro.ProgressBar1.Position := 0;
    FSynchro.BringToFront;

    Enabled := false;

    for i:= 0 to 100 do
    begin
        if FSynchro.bStoped then break;
        FSynchro.ProgressBar1.Position := i;
        Application.ProcessMessages;
        Sl eep( 50 );
    end;

    Enabled := true;
end;


Thanks
Posted 20 Jul, 2011 10:42:44 Top
Andrei Smolin


Add-in Express team


Posts: 18827
Joined: 2006-05-11
Hi Stan,

There's no such possibility. You need to open a modal form or develop a synchronization mechanism. I will be able to tell you more , if you provide more details about your task.


Andrei Smolin
Add-in Express Team Leader
Posted 20 Jul, 2011 11:34:01 Top
Stan




Posts: 13
Joined: 2011-06-09
Andrei Smolin wrote:
There's no such possibility. You need to open a modal form or develop a synchronization mechanism. I will be able to tell you more , if you provide more details about your task.


I chose a simple solution:
I created a modal dialog box that has a reference TadxCOMAddInModule.

This works well.
Thank you for your help.
Posted 21 Jul, 2011 05:43:35 Top
Andrei Smolin


Add-in Express team


Posts: 18827
Joined: 2006-05-11
You are welcome.


Andrei Smolin
Add-in Express Team Leader
Posted 21 Jul, 2011 05:54:21 Top