Rad RadToolTipManager in VB

2 posts, 0 answers
  1. Noor
    Noor avatar
    1 posts
    Member since:
    Feb 2013

    Posted 28 Feb 2013 Link to this post

    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
      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
                    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

            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"
    <telerik:RadCalendar ID="RadCalendar2" RangeMinDate="3/1/2007" runat="server" Width="100%"
        Height="200px" Skin="Default" OnDayRender="RadCalendar2_DayRender" RangeMaxDate="3/30/2014">

  2. Marin Bratanov
    Marin Bratanov avatar
    3561 posts

    Posted 01 Mar 2013 Link to this post

    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.

    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.
  3. DevCraft R3 2016 release webinar banner
Back to Top