Hi everyone, basic question that could use someone to enlighten me on...
I noticed that the Net.HttpWebRequest class is not initialized using the New Keyword, instead you need to call a shared method, Create.
Why is this? Why didn't they just create an overloaded New sub? I think it makes it more confusing, but I am sure there is a reason this and many other classes do it this way...:confused:
I noticed that the Net.HttpWebRequest class is not initialized using the New Keyword, instead you need to call a shared method, Create.
Code:
Dim req As Net.HttpWebRequest = Net.HttpWebRequest.Create("http://example.com")