Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsModulesModulesCustom module with AJAX CalendarextendarCustom module with AJAX Calendarextendar
Previous
 
Next
New Post
1/28/2011 9:59 AM
 
Hi.. I have created a DNN module and have a textbox that I am trying to get the AJAX calendarextender to work and I am having no luck.. this is what i have for my code..

in the .ascx file

<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="cc1" %>

<asp:TextBox ID="txtBoxOrgPurchaseDate" runat="server" Font-Bold="True"></asp:TextBox>


              
                 <cc1:CalendarExtender ID="txtBoxOrgPurchaseDate_CalendarExtender" 
                     runat="server" Enabled="True" TargetControlID="txtBoxOrgPurchaseDate">
                 </cc1:CalendarExtender>


then in my codebehind


Namespace AJAXControlToolkit


    Partial Class AJAXControlToolkit
        Inherits DotNetNuke.Entities.Modules.PortalModuleBase


        Protected Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
            Try
                If DotNetNuke.Framework.AJAX.IsInstalled Then
                    DotNetNuke.Framework.AJAX.RegisterScriptManager()
                End If
            Catch exc As Exception        'Module failed to load
                ProcessModuleLoadException(Me, exc)
            End Try
        End Sub


    End Class


End Namespace
 
New Post
1/28/2011 11:42 AM
 
Some initial thoughts I had when looking at your code is that your code behind uses the namespace AJAXControlToolkit and your partial class is called "AJAXControlToolkit". I've never seen that and intuitively it seems like you shouldn't do that.

I can only imagine the types of conflicts that happen between your project and the actual toolkit when you make a class called "AJAXControlToolkit". The namespace in your codebehind should be the namespace in your project. The partial class name should represent the ascx file. You don't need put your class inside the AJAXControlToolkit namespace, you can just import the namespace/dll using an import at the top of your file.

 I would suggest removing the namespace "AJAXControlToolkit" from your codebehind and using a namespace in your project. I would also suggest renaming your partial class in your codebehind to something other than "AJAXControlToolkit". Are you getting any errors? If so, could you post them here?
 
New Post
1/28/2011 3:11 PM
 
this is what i have now..

my pricingsurvey.ascx.asxc page
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="cc1" %>

<asp:TextBox ID="txtBoxOrgPurchaseDate" runat="server" Font-Bold="True"></asp:TextBox>


              
                 <cc1:CalendarExtender ID="txtBoxOrgPurchaseDate_CalendarExtender" 
                     runat="server" Enabled="True" TargetControlID="txtBoxOrgPurchaseDate">
                 </cc1:CalendarExtender>




my code behind

#Region "Imports"
'System Imports
Imports System
Imports System.Drawing
Imports System.Web.UI.WebControls
Imports System.Collections
Imports System.Collections.Generic
Imports System.Reflection
Imports System.Web.UI
Imports System.Data
Imports System.Data.Sql
Imports System.Data.SqlClient
Imports System.Linq
Imports System.IO
Imports System.Xml
Imports System.Text
Imports System.Security.Cryptography
Imports System.Net


'Custom DNN imports
Imports DotNetNuke
Imports DotNetNuke.Common
Imports DotNetNuke.Services.Search
Imports DotNetNuke.Services.Exceptions
Imports DotNetNuke.Entities.Portals
Imports DotNetNuke.Security.Roles
Imports DotNetNuke.Services.Localization
Imports DotNetNuke.UI.WebControls
Imports DotNetNuke.Common.Controls
Imports DotNetNuke.Entities
Imports DotNetNuke.Entities.Tabs
Imports DotNetNuke.Security.Permissions
Imports DotNetNuke.Common.Utilities
Imports DotNetNuke.Modules.Html
Imports DotNetNuke.Entities.Modules


Imports AuthorizeNet
Imports AuthorizeNet.Helpers


Imports AjaxControlToolkit
#End Region


'Jordan VanderFlier
'Software Engineer
'Copyright 2011


Namespace Mainsail.DNN.Module.Jordan
    Partial Class pricing_survery
        Inherits Entities.Modules.PortalModuleBase


        Dim queryStringYear As String
        Dim queryStringModel As String
        Dim firstName As String
        Dim lastName As String
        Dim email As String


        Dim mileage As Integer


        Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load


            Try
                If DotNetNuke.Framework.AJAX.IsInstalled Then
                    DotNetNuke.Framework.AJAX.RegisterScriptManager()
                End If
            Catch exc As Exception 'Module failed to load
                ProcessModuleLoadException(Me, exc)
            End Try






            queryStringYear = Request.QueryString("y")
            queryStringModel = Request.QueryString("m")


            ' Checks to see if query string is null
            If (queryStringYear = Nothing Or queryStringModel = Nothing) Then
                Panel1.Visible = False
                panelSelectVehicle.Visible = True
            Else
                Dim crypt As New Encryption64
                queryStringYear = crypt.Decrypt(queryStringYear, "!#$a54?3")
                queryStringModel = crypt.Decrypt(queryStringModel, "!#$a54?3")


                ltlYealModel.Text = "<b>" + queryStringYear + " " + queryStringModel + "</b>"
            End If
        End Sub
End Class
End Namespace


im still having issues getting it to show when i click on the text box????
 
New Post
3/2/2012 2:56 PM
 

hi,

I am wondering if you have found the solution for this your problem? I have same problem and i don't know how solve it.

I would appreciated if you could help me.

thanks,

 
New Post
3/9/2012 4:06 AM
 

Hi,

I've benn messing with that a while ago with no sucess. Then, I tried the DnnDatePicker and it works like a charm without using the toolkit. Actually, you have a full set of DNN/Telerik AJAX controls you can use inside DNN.

 
Previous
 
Next
HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsModulesModulesCustom module with AJAX CalendarextendarCustom module with AJAX Calendarextendar


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out