Typically you create a Vector (strongly typed array) specifying a data type like:
new Vector<PictureBox>();
However I need to create a utility method that should be able to create a vector of any given datatype. Is it possible to specify a type using a variable instead of hard-coding it?
var type:Class = PictureBox;
new Vector<type>();
You cannot do it exactly the way you want, but you could use a set of classes which implement the same interface, and then type your vector with that interface, e.g.: