vb.net - STATHHREAD attribute required if application contains object that implements IDisposable -
i looking @ number of windows forms applications have no user interface , have no sta thread (http://msdn.microsoft.com/en-gb/library/system.stathreadattribute.aspx) attribute above main thread.
i have not created com components used in these applications.
i have read following thread: stathread , multithreading. bruce states: "apartment threading com concept; if you're not using com, , none of apis call use com "under covers". there way of finding out if classes use com: "under covers"?
in past see if class implements idisposable e.g. sqlconnection implements idisposable must contain unmanaged resources i.e. comcomponents.
is safe if windows application or console application references object implements idisposable, main thread should contain stathread attribute above it?
Comments
Post a Comment