"object" problem
-
I try to build a Form template in VB.Net so later on i can inherit the form template. in VB.NET i can use
Public SearchForm As Object; 'Without instance the real SearchForm Class object 'The real SearchForm will be instance in the inherit form. 'in the init. method SearchForm.Show();
the base class sucessfully Compile. But in C#public object SearchForm 'Without instance the real SearchForm Class object 'The real SearchForm will be instance in the inherit form. 'in the init. method SearchForm.Show()
but in C# i can't compile it.. an error message come out : 'object' does not contain a definition for 'Show' :(Please help ... urgent ... -
I try to build a Form template in VB.Net so later on i can inherit the form template. in VB.NET i can use
Public SearchForm As Object; 'Without instance the real SearchForm Class object 'The real SearchForm will be instance in the inherit form. 'in the init. method SearchForm.Show();
the base class sucessfully Compile. But in C#public object SearchForm 'Without instance the real SearchForm Class object 'The real SearchForm will be instance in the inherit form. 'in the init. method SearchForm.Show()
but in C# i can't compile it.. an error message come out : 'object' does not contain a definition for 'Show' :(Please help ... urgent ...That's obvious: "'object' does not contain a definition for 'Show'". The type object does not provide a method called Show. Your variable SearchForm must be of type Form, which provides this method.
-
That's obvious: "'object' does not contain a definition for 'Show'". The type object does not provide a method called Show. Your variable SearchForm must be of type Form, which provides this method.