Avoiding flicker with this inspector - help!

J

jase

I'm using the following code:

With objContact
.FullName = objRecip.Name
.Email1Address = strAddress
.Save
.Display
ActiveInspector.WindowState = olMinimized
End With

the last two lines create a flicker when the inspector is displayed and
then minimised - how do i work around this annoying little glitch

help greatly appreciated
jason
 
M

Michael Bauer

Hi Jason,

why do you call the last two lines? Commenting them out will avoid the
flickering for sure.
 
J

jase

Cheers Michael,

This code is in the ThisOutlokSession module and runs when mails are
sent: it is part of a procedure that adds addresses to my contacts if
the address does not already exist: I'd like to be able to know which
contacts have just been added so that there is a chance to edit the
details or even delete the contact: if they appear minimised then I
know something needs doing.

anymore help appreciated
Jason.
 
M

Michael Bauer

Hi Jason,

I´d display a ListBox maybe on a UserForm instead of having opened a lot
of Contacts.

For avoiding the flickering there seems to be no way. I´ve tried with a
LockDesktopUpdate but that raises an error, too, if you want to set the
WindowState before the Inspector is displaying.

You could do this: call GetInspector for a reference before the
Inspector is displaying, set the Inspector´s Left property to a big
negative value (e.g. -20,000), call its Display method and them minimze
the window.

The tricky part is, you can´t reset the Left property while the
WindowState is minimized. Therefor you probably need to track the
Inspector´s Activate event.
 
J

jase

Cheers Michael
Think I'll get together a "Most recently added contacts" userform with
a list of all recently added: with options to open/modify or delete.
Nice workaround matey
Thanks
Jason
 
Top