Thread: Question Override Controls Property
View Single Post
  #1 (permalink)  
Old 01-07-2009, 6:18 AM
prav_roy prav_roy is offline
VB.NET Forum Enthusiast
.NET Framework: .NET 2.0 (VS 2005)
 
Join Date: Sep 2005
Location: Mumbai
Age: 30
Posts: 70
Reputation: 59
prav_roy is on a distinguished programming path ahead
Default Override Controls Property

Hi,
I have used NumericUpdown Control in my project, control appears in all most all forms, you may be aware of the fact that minimu and maximum value of numericupdown is 0 and 100 resp by default.
Now let me come to the problem i want to override this propert of Numericupdown to set min and max value, my code looks like

Public Class NumericControl
Inherits NumericUpDown

Public Overloads Property Minimum() As String
Get
Return MyBase.Minimum = 0
End Get
Set(ByVal value As String)
MyBase.Minimum = value

End Set
End Property
Public Overloads Property Maximum()
Get
Return MyBase.Maximum = 10000
End Get
Set(ByVal value)
MyBase.Maximum = value
End Set
End Property
End Class


But it doesnt work
any suggestion from your side

Regards

Praveen
Reply With Quote