ADX and flicker and title bar disappearing

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

ADX and flicker and title bar disappearing
 
Jason Coley




Posts: 272
Joined: 2005-05-26
OK, i have a right Pane and a command bar button. The command bar button Enabled/disables the Right Pane. There are no controls on the Pane as yet.

if cbStandard.Controls[0].AsButton.State = adxMsoButtonUp then
begin
cbStandard.Controls[0].AsButton.State := adxMsoButtonDown;
adxOlFormsManager1.Items[0].Enabled := True;
end
else
begin
cbStandard.Controls[0].AsButton.State := adxMsoButtonUp;
adxOlFormsManager1.Items[0].Enabled := False;
end;

OK pretty simple, but when I do this, the screen flickers quite a bit, and the header, above the actual explorer view contents disappears when the pane does. (The header that displayes the folder name as you switch through the folders).

The Pane is set to show in contact folders only.

Any ideas, I am using BDS2006 Delphi Win32, and tried both Outlook 2003 and 2007, 2007 the header panel doesn't disappear, but there is other odd drawing things happening.

Jason
Posted 10 Oct, 2006 03:29:27 Top
Fedor Shihantsov


Guest


I don't quite understand you. Could you please send me some screenshots? Use my support e-mail address.
Posted 10 Oct, 2006 06:15:48 Top
Jason Coley




Posts: 272
Joined: 2005-05-26
Hmm, it seems to have gone at present in Outlook 2k3, after installing SP1, i'll keep an eye on this.

As for the flickering, I understand the control navigates Outlook to the sent items folder then back to reapint things, I am wondering is there any way to Lock the window updates during this process? How would I get the handle to the Outlook window so I can try using LockWindowUpdate around the enabling to see if this will help?

Jason
Posted 10 Oct, 2006 06:24:49 Top
Fedor Shihantsov


Guest


You can use the following code for getting the handle.


IOleWindow = interface(IUnknown)
  ['{00000114-0000-0000-C000-000000000046}']
  function GetWindow(out wnd: HWnd): HResult; stdcall;
  function ContextSensitiveHelp(fEnterMode: BOOL): HResult; stdcall;
end;

function GetExplorerWindowHandle(explorer: IDispatch):HWND;
var
  IWindow: IOleWindow;
begin
  Result := 0;
  if explorer = nil then exit;
  explorer.QueryInterface(IOleWindow, IWindow);
  if Assigned(IWindow) then IWindow.GetWindow(Result)
end;
Posted 10 Oct, 2006 06:49:53 Top
Jason Coley




Posts: 272
Joined: 2005-05-26
Cool thanks for that, however it didn't work, so I have just decided to make the width 0 when not in use and all code that runs on selection change to not run if width is 0, this seems to be the best way around the issue.

Jason
Posted 10 Oct, 2006 16:55:29 Top