Home > Microsoft Exchange Tips > Exchange Server Administration Tips > Prototyping and debugging Exchange event sinks
Exchange Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

EXCHANGE SERVER ADMINISTRATION TIPS

Prototyping and debugging Exchange event sinks


Serdar Yegulalp
05.12.2005
Rating: -2.50- (out of 5)


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


Please let others know how useful this tip is via the rating scale at the end of it. Do you have a useful Exchange or Outlook tip, timesaver or workaround to share? Submit it to our tip contest and you could win a prize.


Exchange event sinks are pieces of code that are triggered by specific Exchange events. For instance, an administrator can create an event sink that fires when a piece of e-mail is received, or when other specified conditions arise. This makes it possible to customize or add to Exchange's functionality in many ways.

Event sinks can be useful, but they can also be tricky. What works perfectly well in controlled testing may not work in a live environment at all, no thanks to unexpected interactions between user accounts and mailbox permissions, or the vagaries of e-mail in general. Because of this, if you're writing custom event sinks for your organization that are going to be deployed as compiled objects (.DLLs), the live debugging process can be painful and complicated.

.DLLs for event sinks not only have to be registered with the system, but run in the context of a specific COM+ application. If you have to take a .DLL offline and replace it with an updated version, the procedure usually goes something like this:

  1. Un-register the event sink .DLL.
  2. Stop the COM+ app for this event sink.
  3. Compile a new version of the event sink if this hasn't been done already.
  4. Refresh and restart the COM+ app.
  5. Re-register the event sink.

Since the only way to reliably test an event sink is in situ, un-registering and re-registering successive versions of the same component can become tiresome and time-consuming. One way to work around problems like this is to code a prototype version of the event sink in VBScript and then later convert it to a .DLL in VB6. First, the code used can be virtually identical; the changes needed to make a VBScript program work as a full Visual Basic application are minimal. Second, the VBScript code can be edited on the fly and does not need to be removed and re-registered when changed.

About the author: Serdar Yegulalp is editor of the Windows Power Users Newsletter and a regular contributor to SearchExchange.com.


Do you have comments on this tip? Let us know.
Related information from SearchExchange.com:

  • Topics Library: Exchange scripts and programming



    Rate this Tip
    To rate tips, you must be a member of SearchExchange.com.
    Register now to start rating these tips. Log in if you are already a member.




    Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


    RELATED CONTENT
    Microsoft Exchange Server Scripts and Programming
    How to run Exchange Management Shell cmdlets in Exchange Server 2007
    Automate complex Exchange 2007 Management Shell tasks via scripting
    Exchange event sink scripting error when configuring email disclaimer
    EMS add-on tool generates graphical Exchange Server 2007 reports
    A primer on the Exchange Server 2007 Exchange Management Shell
    How to generate HTML reports with the Exchange Management Shell (EMS)
    Use the Exchange Management Shell Set command to block senders
    How to test Exchange Management Shell commands
    Grant or deny permissions to access a user's Exchange 2007 mailbox
    Control query results with Exchange Management Shell's Format command

    Exchange Server Administration Tips
    Top 10 Microsoft Exchange Server tips of 2008
    Database changes that enhance Exchange Server 2007 fault tolerance
    How continuous replication methods affect Exchange 2007 log shipping
    Analyzing Exchange ActiveSync data from .CSV report files
    How to run Exchange Management Shell cmdlets in Exchange Server 2007
    Eliminate .PST file use for secure email retention in Exchange 2007
    Exchange Server 2007 log shipping and continuous replication
    Benefits of backing up Exchange Server with Microsoft's DPM 2007
    Exchange Server 2007 replication and database transaction basics
    Microsoft Exchange Server 2003 database recovery methods

    RELATED GLOSSARY TERMS
    Terms from Whatis.com − the technology online dictionary
    application program interface  (SearchExchange.com)
    event sink  (SearchExchange.com)
    synchronous groupware  (SearchExchange.com)

    RELATED RESOURCES
    2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
    Search Bitpipe.com for the latest white papers and business webcasts
    Whatis.com, the online computer dictionary

    DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



  • Email Server Solutions: Exchange 2007, Exchange 2003, Exchange 2000, SharePoint
    HomeNewsTopicsITKnowledge ExchangeTipsAsk the ExpertsMultimediaWhite PapersIT Downloads
    About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
    SEARCH 
    TechTarget provides enterprise IT professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective IT purchase decisions and managing their organizations' IT projects - with its network of technology-specific Web sites, events and magazines.

    TechTarget Corporate Web Site  |  Media Kits  |  Site Map




    All Rights Reserved, Copyright 2004 - 2009, TechTarget | Read our Privacy Policy
      TechTarget - The IT Media ROI Experts