ProblemYou need to create an instance of a class or structure. SolutionUse the New keyword to create a new class or structure instance. DiscussionThere are three basic places you use the New keyword:
All three uses of New can be intermixed within the same block of code, and you can choose what best fits the needs and logic of the code block. See AlsoThe New keyword is also used in a different context to create class constructors. See Recipe 3.6 for additional details. |