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

Problem in UpdateToolTip()

1 Answer 86 Views
ToolTip
This is a migrated thread and some comments may be shown as answers.
jpchenot
Top achievements
Rank 2
jpchenot asked on 21 Jan 2008, 09:31 AM
HI.

When I write the code to update the tooltip in my vb code I get the error:
    - Cannot convert type system.web.ui.control to content.

Content is my web usercontrol. Here is my code

Private

Sub UpdateToolTip(ByVal elementID As String, ByVal panel As UpdatePanel)
Dim ctrl As UserControl = Page.LoadControl("~/secured/admin/Content.ascx")   panel.ContentTemplateContainer.Controls.Add(ctrl)
Dim content As Content = DirectCast(ctrl, Content)
content.ContentID = elementID
End Sub

The error is on the ctrl element. I have copied the code from the demo, so it should work. I don't understand what's wrong.

regards,

Jean-Philippe

1 Answer, 1 is accepted

Sort by
0
Tsvetie
Telerik team
answered on 22 Jan 2008, 01:33 PM
Hello Jean-Philippe,
Please make sure that you have the following line in your aspx:
<%@ Register Src="Content.ascx" TagName="Content" TagPrefix="uc1" %> 

In case this does not solve the problem, please open a new support ticket and send us a simple running project, demonstrating it.

Kind regards,
Tsvetie
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
ToolTip
Asked by
jpchenot
Top achievements
Rank 2
Answers by
Tsvetie
Telerik team
Share this question
or