Answer Posted / rohit
Whatever the code written by Sonia.sardana is shows the
shadowing concept but there is some print mistakes in the
code.The correct code is---
imports system
module m1
public class base
Public Sub test()
Console.WriteLine("sonia")
End Sub
Public Sub test(ByVal i As Integer)
Console.WriteLine(i)
End Sub
End Class
Public class derived
inherits base
Shadows Sub test(ByVal x As Integer)
Console.WriteLine("Shadow method")
End Sub
end class
Sub main()
Dim obj As New derived
obj.test() 'This will show error
obj.test(10) 'This is valid
End Sub
end module
| Is This Answer Correct ? | 8 Yes | 6 No |
Post New Answer View All Answers
Explain private assembly?
What are nested classes?
What is an application domain? how they get created?
What is private assembly?
Explain about the keyword must inherit?
Describe about visual basic.net?
What are the difference between dispose(), close(), exit(), end()?
Explain enumerator?
Can you please explain the difference between authentication and authorization?
Explain how does the xmlserializer work?
What is code security?
what is difference between web.config and machine.config and where it will be ?
What is the class that allows an element to be accessed using unique key?
my project run very wel in my sytem yhen i am deploying my project on client machine ,after deployment i run my project then it show " can no find server name " what i do .
What is globalization?