By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,343 Members | 925 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,343 IT Pros & Developers. It's quick & easy.

STAThread

P: n/a
Tom
Do we need to put the STAThread attribute on our Sub Main anymore if we are
using the 1.1 Framework? See some YEAs and NEAs when searching on Google so
thought I would ask here.

Tom
Nov 20 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Tom,
My understanding is that VB.NET will add STAThread attribute for you if you
do not explicitly include the STAThread or MTAThread attribute on your sub
main.

Using ILDASM.EXE on a number of my projects have confirmed this
understanding.

Hope this helps
Jay

"Tom" <to*@nospam.com> wrote in message
news:Ot**************@TK2MSFTNGP11.phx.gbl...
Do we need to put the STAThread attribute on our Sub Main anymore if we are using the 1.1 Framework? See some YEAs and NEAs when searching on Google so thought I would ask here.

Tom

Nov 20 '05 #2

P: n/a
* "Tom" <to*@nospam.com> scripsit:
Do we need to put the STAThread attribute on our Sub Main anymore if we are
using the 1.1 Framework? See some YEAs and NEAs when searching on Google so
thought I would ask here.


It's STA by default, you don't need the 'STAThread' attribute.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.