Hello
I have added a telerik dtp to a 'chunk' in a Ribbonbar as follows in the onLoad event of a form. The purpose is to change the view of a calendar when the value in the dtp is changed. The code below accomplishes this task as expected:
The handler that I added is as follows:
However, I would like to change the value of the dtp if a new date is clicked on the calendar itself - how can I reference the dtp in the Ribbonbar and change the value that is displayed?
I found some code from another post - I can find the dtp by doing this (I think) but have not been successful in updating the value...
For Each ct As RadItem In Me.chunkJumpTo.Items
If ct.Name = "ggPicker" Then
...CHANGE VALUE HERE...
End If
Next
QUESTION 2:
I have several RadImageButtonElements in my Ribbonbar. I have set the ImageHovered property on several buttons but the new image is not displayed on hover of the button - are there issues with this property? Can you please demonstrate how to display a second image on hover and then revert to this original?
Thank you
Brian
I have added a telerik dtp to a 'chunk' in a Ribbonbar as follows in the onLoad event of a form. The purpose is to change the view of a calendar when the value in the dtp is changed. The code below accomplishes this task as expected:
Dim dtPicker As New RadDateTimePicker
dtPicker.ThemeName = "Office2007Blue"
AddHandler dtPicker.ValueChanged, AddressOf pickerValueChanged
Dim hostItem As New Telerik.WinControls.RadHostItem(dtPicker)
hostItem.MinSize = New System.Drawing.Size(150, 50)
Me.chunkJumpTo.Items.Add(hostItem)
Me.chunkJumpTo.Items(0).Name = "ggPicker"
The handler that I added is as follows:
Private Sub pickerValueChanged(ByVal sender As System.Object, ByVal e As System.EventArgs)
Dim dtp As RadDateTimePicker = sender
selectedDate = dtp.Value
Select Case Me.Calendar1.CurrentView
Case WinForms.CalendarView.WeekRange
viewMonth()
Me.Calendar1.Selection.Set(selectedDate)
Case WinForms.CalendarView.Timetable
If Calendar1.TimetableSettings.VisibleColumns > 1 Then
viewWeek()
Me.Calendar1.Selection.Set(selectedDate)
Else
viewDay()
End If
End Select
setCurrentMonth()
End Sub
However, I would like to change the value of the dtp if a new date is clicked on the calendar itself - how can I reference the dtp in the Ribbonbar and change the value that is displayed?
I found some code from another post - I can find the dtp by doing this (I think) but have not been successful in updating the value...
For Each ct As RadItem In Me.chunkJumpTo.Items
If ct.Name = "ggPicker" Then
...CHANGE VALUE HERE...
End If
Next
QUESTION 2:
I have several RadImageButtonElements in my Ribbonbar. I have set the ImageHovered property on several buttons but the new image is not displayed on hover of the button - are there issues with this property? Can you please demonstrate how to display a second image on hover and then revert to this original?
Thank you
Brian