Library code snippets

Using MSMQ to persist your COM

I wont go into the details of using MSMQ, you can figure out yourself by looking at the code but the important thing is how we used the property bag to store the information and then later retrieve that information from the property bag to send via MSMQ.

Just look at the code of the class how we made the component persistable by storing the information in the property bags. A property bag object holds information  that is to be saved and  restored across invocations of an object.

A property bag object is passed into an object through the  readproperties event and the writeproperties event in order to save and restore the state of the object. Using the methods of the property bag object, the object can read or write properties of itself. The readproperty method of the propertybag is used to read a value for a property, while the writeproperty method of the propertybag object is used to write a value of a property. The value of a property can itself be an object; in that case the propertybag object will attempt to save it. Also, the code will show you how to use the MSMQ to pass a persistable component to the MSMQ Server.

Comments

  1. 01 Jan 1999 at 00:00

    This thread is for discussions of Using MSMQ to persist your COM.

Leave a comment

Sign in or Join us (it's free).

S.S. Ahmed S.S. Ahmed is a senior IT Professional and works for a web and software development firm. Ahmed is a Microsoft Office SharePoint Server MVP. Ahmed specializes in creating database driven dynamic we...
AddThis

Related discussion

Related podcasts

  • Christian Beauclair

    14 mai 2008 (�mission #0074) ::.Christian Beauclair: Stratégies de migration VB6 vers .NET Nous discutons avec Christian Beauclair des stratégies de migration VB6 vers .NET. Entre autres, nous discutons comment utiliser le "VB 6 Code Advisor" et le "Interop Forms Toolkit" pour ajouter la puiss...

Want to stay in touch with what's going on? Follow us on twitter!