Outlook 2003 hangs on send/receive

G

g62msdnatll

I've written an add-in that hooks into nearly all the events that Outlook
might generate. On my machine, I don't see any running problems. However,
when I installed the add-in on other machines, I'm seeing two problems.

1) On one machine, when user clicks the "Send" button to send an item,
Outlook "hangs" (displays the hourglass cursor) and the UI fails to repaint
the screen properly, until the user generates a mouse click. Once the user
clicks the mouse, operation returns to normal, and the item is sent, and the
UI is repainted.

2) On another machine, the user has a very large mailbox on an IMAP server.
When the add-in is installed, Outlook hangs and seems to be making no
progress toward loading and displaying all the messages. It appears to hang
on the action of "downloading hierarchy" or "downloading headers"

Any idea what might be causing this behavior? I don't see either behavior
on my dev machine.

Thank you.
 
G

g62msdnatll

Addendum:

regarding the first problem, if the user changes windows through any means
(such as alt-tab), not just a mouse-click, sending also continues
 
P

Peter Huang [MSFT]

Hi

Is there a large hardware configuration gap between your machine/server and
problem machine/server?
Is there any other Addin/ Rules defined in the problem machine, please
disabled them temporarily for test.
Aslo I think you may try to log all the event hook.
e.g.
In the first line of ItemSend event hook function, try to write a log to a
file, so that we may know what outlook doing when it is "Hang"/Slow.
Which event take a long time?

Please perform the test and let me know the result.
Thanks!

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 
G

g62msdnatll

I added a print statement at the beginning of the send event. Outlook is not
hanging on the add event.

However, I noticed that the Inspector.Close event is not firing. My
Inspector.Close event handler:

public static void inspector_Close()
{
//TODO: how to tell which inspector got closed?
OutlookLogger.LogComment(Connect.fn, "Entering Inspector.Close event -
print message for debug");
Collections.StringCollection strCollection = new
System.Collections.Specialized.StringCollection();
strCollection.Add(LogType.Event_Inspector_Close);
OutlookLogger.Append(ref strCollection, OutlookLogger.SystemTimestamp());
OutlookLogger.Log(Connect.fn, strCollection);
}

The logger just writes to a logfile like any other event.

Ideas?
 
P

Peter Huang [MSFT]

Hi
I added a print statement at the beginning of the send event. Outlook is not
hanging on the add event.

Do you mean outlook is not hanging on the send event but not the add event?
If so, have you try to print at the end of the send event handler to ensure
the event has been passed.

What about the ItemSend event, did that pass too?

Also Have you tried the OnError Event, if there is any error occur?

Occurs when Microsoft Outlook encounters an error while synchronizing a
user¡¯s folders using the specified Send\Receive group. This event is not
available in Microsoft Visual Basic Scripting Edition (VBScript).

Can you provide some information about the different between your machine
and the problem machine which in my last post?
e.g. the hardware configuration difference, the mail server difference, if
there is any addin...?
It is hard to guess what is happened based on the information so far.

Also I think you may try to contact MSPSS direct which will collect dump
and do analyse on the problem machine to do further troubleshooting.
http://support.microsoft.com

Thanks for your understanding!

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 
G

g62msdnatll

Machine differences:

As far as I know, there are no differences between my machine and the
machine with the bugs. We both have Windows XP and Office 2003 installed,
..NET framework, and the .NET framework hotfix.

Can you please tell me where in the Outlook OM I can find the OnError event?
Is it an Application event?

One problem I am noticing is that on the buggy machine, the
Inspector.Activate event fires twice for ONE New_Inspector event. This does
not happen on my machine.

I will perform the tests you suggested, please let me know where I can find
the OnError event.

Thank you.
 
P

Peter Huang [MSFT]

Hi

I am sorry if I have any confusion.

Here is some reference about OnError event.

OnError Event
See AlsoApplies ToExampleSpecificsOccurs when Microsoft Outlook encounters
an error while synchronizing a user¡¯s folders using the specified
Send\Receive group. This event is not available in Microsoft Visual Basic
Scripting Edition (VBScript).

Sub object_OnError(ByVal Code As Long, ByVal Description As String)
object An expression that evaluates to a SyncObject object.

Code A unique value that identifies the error.

Description Required. A textual description of the error.

Example
This Microsoft Visual Basic/Visual Basic for Applications (VBA) example
displays a message box describing the synchronization error when an error
occurs during synchronization. The sample code must be placed in a class
module, and the Initialize_handler routine must be called before the event
procedure can be called by Microsoft Outlook.

Dim myOlApp As New Outlook.Application
Public WithEvents mySync As Outlook.SyncObject

Sub Initialize_handler()
Set mySync = myOlApp.Session.SyncObjects.Item(1)
mySync.Start
mySync.Stop
End Sub

Private Sub mySync_OnError(ByVal Code As Long, ByVal Description As String)
MsgBox "Unexpected sync error" & Code & ": " & Description
End Sub

This can be found in the outlook VBA helper file.
<Program Files>\Microsoft Office\OFFICE11\1033\VBAOL11.CHM

Also are you using the same mail server?
Can you provide the information as I post in my last post?
Because the Download progress is to download information from server, so it
may be caused by the Server or Network BandWidth.
To isolate the problem you may also try to disable the addin to see if
there is any difference.

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 
K

Ken Slovak - [MVP - Outlook]

One other thing to check is if the difference is in using WordMail or not.
That can cause multiple Activate events, as can the user clicking Next or
Previous.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top