Basically, you probably shouldn't - it's against the principles of OOPs.
If you have two forms: a Parent form which creates and displays a Child form, then OOPs says that the Child should be independent: it should have no idea that the Parent even exists, much less what type it is. Indeed, once the Child has been created, the Parent could even be Closed and Disposed and it should have no affect on eth application (unless it it the main application form, in which case the app closes as well)
Instead, the child should communicate back to the Parent via Properties and Events, just like Controls on your Forms do at the moment.
Have a look here:
Transferring information between two forms, Part 1: Parent to Child[
^]
Transferring information between two forms, Part 2: Child to Parent[
^]
Transferring information between two forms, Part 3: Child to Child[
^]
They show teh various ways to do it - teh code is in C# but it';s pretty easy to follow and online converters can help if you don't understand the syntax:
Code Converter C# to VB and VB to C# – Telerik[
^]
But if there is a really, really good reason why you need to get information on a form's creator, it is available in the Load event hander via the
sender
parameter, which holds the instance of the Parent Form:
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Console.WriteLine(sender.GetType())
End Sub
Will show you the class type.
But just because you
can do something, that doesn't mean you
should: if you think that that will help you, you are probably just making life harder for yourself in the future - a lot harder!