tags:

views:

516

answers:

1

I'm refactoring some code I inherited from a long-gone developer, and I find this:

ImportExportForm l_Form = new ImportExportForm();
l_Form.InitializeLifetimeService();
l_Form.ShowDialog();

I've never seen or used the LifetimeService before, but from the little I've read, I don't understand why I would want to use it here, but before saying WTF, I wondered if I might be missing some subtle detail?

+2  A: 

As far as I know this is a method normally use for Remote .Net Objects, and to establish the lifetime of an instance. Look here:

http://msdn.microsoft.com/es-es/magazine/cc300474(en-us).aspx

I don't think that it's important for normal Windows Form.

netadictos
I don't know enough about the subject to know if this IS the right answer, but being as SO keeps nagging me to mark answered questions.... I'll give this one the benefit of the doubt.
Benjol