This is a migrated thread and some comments may be shown as answers.

Rad RadToolTipManager in VB

1 Answer 72 Views
ToolTip
This is a migrated thread and some comments may be shown as answers.
Noor
Top achievements
Rank 1
Noor asked on 28 Feb 2013, 11:08 AM

I am using Rad Calendar in my vb project. I am trying to display the meeting details on the tooltip.

I am trying to import Telerik.Web.Examples.ToolTip.ToolTipCalendar using:
But it is showing error. Kindly suggest. I had used the same logic in C#. It is working fine there, but it is not working in vb
Imports Imports Telerik.Web.Examples.ToolTip.ToolTipCalendar

I am using the following code in my default.aspx.vb file:
Protected Sub RadToolTipmanager1_AjaxUpdate(sender As Object, e As ToolTipUpdateEventArgs)
      Dim details As AppointmentDetails = DirectCast(Me.LoadControl("../Admin/UserControls/AppointmentDetails.ascx"), AppointmentDetails)
      details.AppointmentID = e.Value
      e.UpdatePanel.ContentTemplateContainer.Controls.Add(details)
  End Sub

Also i had created a user control AppointmentDetails.ascx.vb


Imports System.Web.Security
Imports System.Web.UI
Imports System.Web.UI.WebControls
Imports System.Web.UI.WebControls.WebParts
Imports System.Web.UI.HtmlControls
Imports System.Drawing
Imports System.IO
 
 
Namespace Telerik.Web.Examples.ToolTip.ToolTipCalendar
 
    Partial Public Class AppointmentDetails
        Inherits System.Web.UI.UserControl
        Private EmpployeeClass As New EmployeeManager()
        Private user As New UserManager()
        Private m_appointmentID As String
 
        Public Property AppointmentID() As String
            Get
                Return m_appointmentID
            End Get
            Set(value As String)
                m_appointmentID = value
            End Set
        End Property


        Protected Sub Page_PreRender(sender As Object, e As EventArgs)
            Me.AppointmentsDataSource.SelectParameters("ID").DefaultValue = Me.AppointmentID.ToString()
            GridView1.DataSource = AppointmentsDataSource
            GridView1.DataBind()

        End Sub

    End Class
End Namespace


and the default.aspx file contains

<telerik:RadToolTipManager Width="250px" HideDelay="0" RelativeTo="Mouse" ID="RadToolTipManager2"
    runat="server" Position="TopRight" OnAjaxUpdate="RadToolTipmanager1_AjaxUpdate"
    AutoCloseDelay="0">
</telerik:RadToolTipManager>
<telerik:RadCalendar ID="RadCalendar2" RangeMinDate="3/1/2007" runat="server" Width="100%"
    Height="200px" Skin="Default" OnDayRender="RadCalendar2_DayRender" RangeMaxDate="3/30/2014">
</telerik:RadCalendar>

1 Answer, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 01 Mar 2013, 12:16 PM
Hi Noor,

What I do not see is a what and where adds targets for your tooltip manager. You also need to make sure the OnPreRender event is attached because AutoEventWireUp is false by default for VB. For your convenienice I have isolated the demo to work with VB and I have attached it here. You can use that as base to incorporate the functionality in your project. Note that you will still need the databases and connection strings from our demos in order to run it.


Greetings,
Marin Bratanov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
ToolTip
Asked by
Noor
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question
or