sti*_*k81 24 .net c# multithreading sta apartment-state
我有一个需要在STA公寓状态下运行的功能.我不想检查它是否作为STA运行,如果没有生成一个在STA中运行的新线程.
如何检查当前线程运行的公寓状态?
Mar*_*rek 31
System.Threading.Thread.CurrentThread.GetApartmentState()
在函数内使用此方法或类似方法:
System.Threading.Thread.CurrentThread.GetApartmentState
| 归档时间: | 
 | 
| 查看次数: | 5271 次 | 
| 最近记录: |