Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
109 views
I have an extended radcombobox item call FeatureComboBoxItem that adds a featureID to the radcomboboxitem.  I'd like to have these types of objects used instead of the normal radcombobox item when automatically databinding from a sqldatasource control.  To support this I extended the radcombobox to include a string property that tells the name of the column used to populate the featureID of the FeatureComboBoxItem.  I figured there was a function I could overwrite to return FeatureComboBoxItems instead of the normal radcomboboxitem but I got lost.  Is it possible to use a different type of object for the item or am I stuck with using a radcomboboxitem?

Public Class FeatureBoxItem
    Inherits Telerik.Web.UI.RadComboBoxItem
    Implements IFeatureItem

    Public Property FeatureID As System.Guid Implements IFeatureItem.ID
        Get
            Return If(ViewState("FeatureID"), Guid.Empty)
        End Get
        Set(ByVal value As System.Guid)
            ViewState("FeatureID") = value
        End Set
    End Property


    'IFeatureItem implementation hidden


    End Sub
End Class

Public Class FeatureComboBox
Inherits Telerik.Web.UI.RadComboBox

'What do I do in here?
End Class
Daniel
Top achievements
Rank 1
 answered on 13 Jul 2012
10 answers
514 views
hi, being new to the telerik controls i am having a frustrating problem, and probably a so simple one to fix! when using the radupload control (and the standard .net upload file control) i get no issues, when trying to use the asyncupload control i cannot seem to see why the select file button does not bring the window to select the file from the users machine, i at first thought it could be something to do with the control being inside a multiview so moved the control to a simple aspx page and still the select button didnt work, any ideas would be greatly appreciated.

Edited: this is only happening with IE9, firefox and chrome are working fine.

Edited: IE9 in compatibility mode is also working, any advice on how to get this control working for IE9 would be great as the app. is close to being finished.
Dimitar Terziev
Telerik team
 answered on 13 Jul 2012
1 answer
94 views
Hi, my Default.aspx looks like: 

<telerik:RadScheduler ID="RadScheduler1" runat="server" Culture="de-DE"
        DataEndField="BIS" DataKeyField="RAUMID" DataSourceID="SqlDataSource1"
        DataStartField="VON" DataSubjectField="RAUMBEZEICHNUNG" Height="600px"
        HoursPanelTimeFormat="HH:mm" Skin="Black" SelectedView="TimelineView">
     
        <ResourceTypes>
            <telerik:ResourceType AllowMultipleValues="True" DataSourceID="SqlDataSource2"
                ForeignKeyField="RAUMID" KeyField="RAUMID" Name="Resource Type 0"
                TextField="BEZEICHNUNG" />
        </ResourceTypes>
     
    <TimelineView SlotDuration="01:00:00"  NumberOfSlots = "24" ColumnHeaderDateFormat="HH:mm" />
   
    <TimelineView UserSelectable="true" GroupBy="Resource Type 0"
            GroupingDirection="Vertical" />
 
    <DayView DayStartTime = "08:00:00" DayEndTime = "00:00:00"  EnableExactTimeRendering= "true" ShowHoursColumn ="true"/>
     
    </telerik:RadScheduler>
 
    <asp:SqlDataSource ID="SqlDataSource1" runat="server"
        ConnectionString="<%$ ConnectionStrings:Book-IT-LHConnectionString %>"
        SelectCommand="SELECT [RAUMBEZEICHNUNG], [RAUMID], [VON], [BIS] FROM [VIEW_RAUMBUCHUNG]" >
    </asp:SqlDataSource>
 
    <asp:SqlDataSource ID="SqlDataSource2" runat="server"
        ConnectionString="<%$ ConnectionStrings:Book-IT-LHConnectionString %>"
        SelectCommand="SELECT [RAUMID], [BEZEICHNUNG] FROM [VIEW_RAUM]">
    </asp:SqlDataSource>

The Data is displayed correctly. But if i want to switch for example between Timeline and DayView or i want to Edit an Appointment, i get an Error: 
Sys.WebForms.PageRequestManagerServerErrorException

Why is that?

If i Delete the ResourceTyp so i can Switch between the different views and i can edit the Appointment. But theres another Problem. For Example: My Appointment is from 16:00 until 17:00 at 11.07.2012 which is correcly displayed in the Dayview, but in the editMode the Date and the time ist wrong. How can i synchronize that ?

Thanks in advance
Plamen
Telerik team
 answered on 13 Jul 2012
2 answers
160 views
On RadGrid1_DetailTableDataBind event I bound my detail table to a dataset based on parent grid key value
detail table has AutoGenerateColumns="True" and so can be a different set of colums

I need, then, to reorder colums working with their OrderIndex properties

I don't know where to place this feature (reorder)
I tried this 
For Each col As GridColumn In RadGrid1.MasterTableView.DetailTables(0).RenderColumns
                LogManager.WriteToDebugLog("c:\log\", "col.UniqueName " & col.OrderIndex & " " & col.UniqueName)
Next

on RadGrid1_PreRender and on RadGrid1_DetailTableDataBind events with no luck, the autogenerated columns are not yet there.

Do you know what event allows me to see detail tables columns?

Thank you

Jean-Marc
Top achievements
Rank 1
 answered on 13 Jul 2012
1 answer
130 views
Please refer to the attached file.
My submaster page:

<%@ Master Language="VB" MasterPageFile="~/Site.Master" AutoEventWireup="false" CodeBehind="AvailabilityLinksSubMaster.master.vb" Inherits="MSP.AvailabilityLinksSubMaster" %>
<%@ MasterType virtualpath="~/Site.master" %>
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="ajaxToolkit" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
    .Visible
    {
        visibility: visible
    }
    .Invisible
    {
        visibility: hidden
    }
</style>
    <asp:ContentPlaceHolder ID="HeadContent" runat="server">
    </asp:ContentPlaceHolder>
    </asp:Content>

   
<asp:Content ID="Content2" ContentPlaceHolderID="TabContent" runat="server">
   
    <table style="height: 100%; width: 100%; min-height: 420px; margin-top: 0px;">
        <tr>
            <td>
    <div style="position: relative"> 
<ul id="nav">
 <li class="top"><a href="MyAvailability.aspx" class="top_link"><span>Home</span></a></li>
 <li class="top"><a href="#nogo2" id="Availability_Selections" class="top_link"><span class="down">Availability Selections</span></a>
  <ul class="sub">
   <li><a href="MyAvailability.aspx">Availability</a></li>
   <li><a href="Sched_AssocSS_Availability_edit.aspx"> -Edit</a></li>
   <li><a href="Sched_AssocSS_Availability_Extend.aspx">Open Availability</a></li>
            <li><a href="Sched_AssocSS_Availability_Extend_edit.aspx"> -Edit</a></li>
            <li><a href="#nogo33" class="fly">Management</a>
      <ul>
       <li><a href="Availability_Manager_Reset.aspx">Reset</a></li>
       <li><a href="Sched_AssocSS_Availability_Impersonation.aspx">Impersonation</a></li>
      </ul>
     </li>
  </ul>
 </li>
 <li class="top"><a href="#nogo22" id="Documentation" class="top_link"><span class="down">Documentation</span></a>
  <ul class="sub">
   <li><a href="#nogo23">User Guide</a></li>
   <li><a href="#nogo24">Tips</a></li>
  </ul>
 </li>
   
    </ul>

    </div>

   
        </td>
        </tr>
        <tr>
            <td style=" height: 100%; vertical-align: top;" rowspan="0">
                <asp:ContentPlaceHolder ID="TabContent" runat="server">
                    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
                        <Scripts>
                            <%--Needed for JavaScript IntelliSense in VS2010--%>
                            <%--For VS2008 replace RadScriptManager with ScriptManager--%>
                            <asp:ScriptReference Assembly="Telerik.Web.UI"
                                Name="Telerik.Web.UI.Common.Core.js" />
                            <asp:ScriptReference Assembly="Telerik.Web.UI"
                                Name="Telerik.Web.UI.Common.jQuery.js" />
                            <asp:ScriptReference Assembly="Telerik.Web.UI"
                                Name="Telerik.Web.UI.Common.jQueryInclude.js" />
                        </Scripts>
                    </telerik:RadScriptManager>
                   
                </asp:ContentPlaceHolder>
            </td>
        </tr>
    </table>
  
</asp:Content>
 ________________________________________________

My Page:

<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/AvailabilityLinksSubMaster.master" CodeBehind="MyAvailability.aspx.vb" Inherits="MSP.MyAvailability" %>
<%@ MasterType virtualpath="~/AvailabilityLinksSubMaster.master" %>
<%@ Register assembly="System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" namespace="System.Web.UI.DataVisualization.Charting" tagprefix="asp" %>
<%@ Register namespace="Telerik.Web.UI" tagprefix="UI" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        div.RadScheduler .rcOtherMonth
        {
           
           
        }
        div.RadScheduler .rsAllDayHeader,
        div.RadScheduler .rsVerticalHeaderTable div
        {
        font-weight: bold;
        text-align: right;
        }
 
        .rsApt
        {
        width: 45%!important;
       
        }
        .rsAllDayRow .rsWrap
        {
         display:none !important;
        }
        div.RadToolTip table.rtWrapper td.rtWrapperContent
        {
            background-color:none !important;
            background-image: url("../Images/Menu_Bkgrd_Normal2.png") !important;
        }

        .ScreenOnly {display : none;}
    </style>
   
    <link href="App_Themes/Default/Scheduler.Macys.css" rel="stylesheet"
        type="text/css" />
    <link href="App_Themes/Default/Calendar.Macys.css" rel="stylesheet"
        type="text/css" />
   
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="TabContent" runat="server">
    <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
  <script type="text/javascript">
            function TimeRangeOnclick() {
          
     var scheduler = $find('<%=RadScheduler1.ClientID %>');
   
   
    var appointment = scheduler.get_appointments().findByID(59);
    scheduler.editAppointmentWithConfirmation(appointment);
};
      function hideActiveToolTip()
            {
          var tooltip = Telerik.Web.UI.RadToolTip.getCurrent();
          if (tooltip)
                {
              tooltip.hide();
          }
      }

      Sys.WebForms.PageRequestManager.getInstance().add_beginRequest(beginRequestHandler);
      function beginRequestHandler(sender, args)
            {
          var prm = Sys.WebForms.PageRequestManager.getInstance();
          if (args.get_postBackElement().id.indexOf('RadScheduler1') != -1)
                {
              hideActiveToolTip();
          }
      }

      function OnClientRequestStart(sender, args)
            {
          args.set_cancel(true);
          var tooltip = Telerik.Web.UI.RadToolTip.getCurrent();
          if (tooltip)
                {
              var element = tooltip.get_targetControl();
              var apt = $find("<%=RadScheduler1.ClientID %>").getAppointmentFromDomElement(element);
                    <%--
              $get("startTime").innerHTML = apt.get_start().format("MM/dd/yyyy HH:mm");
              $get("endTime").innerHTML = apt.get_end().format("MM/dd/yyyy HH:mm");
                    --%>
              $get("descriptionDiv").innerHTML = "double click to edit your preference";
              tooltip.set_text($get("contentContainer").innerHTML);
          }
      }

  </script>
 </telerik:RadCodeBlock>                       
 
       
    <!-- Start Header -->
<!-- End Header -->
   
                    <table cellpadding="0" cellspacing="0" class="style5" cols="1" width="100%">
                        <tr>
                            <td valign="top">
  <!-- Top Menu -->
  
  <!-- End Top Menu -->
  <!-- Start Workspace --> 
                          <div id="Workspace" align="left" class="style6">
                                    <div id="PrintViewHeader" style="display: none;">
                                        <table border="0" cellpadding="1" cellspacing="1" cols="2" width="98%">
                                            <tbody class="SiteTextSmall">
                                                <tr>
                                                    <td align="center" class="PageHeading">
                                                        Availability</td>
                                                </tr>
                                                <tr class="ScreenOnly">
                                                    <td align="left">
                                                        <span class="SiteTextboldRed">For best results, change your printer setting to
                                                        landscape. </span>
                                                    </td>
                                                </tr>
                                            </tbody>
                                        </table>
                                    </div>
   
   

    <!-- Schedule option -->
                        <table border="0" cellpadding="1" cellspacing="1" cols="1" width="98%">
                                        <tbody class="SiteTextSmall">
                                            <tr>
                                                <td colspan="1" rowspan="1">
                                                    <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" Width="100%">
                                                    <telerik:RadScheduler ID="RadScheduler1" runat="server" DayEndTime="23:59:59"
                                                        RowHeight="16px" SelectedView="WeekView"
                                                        WorkDayEndTime="8.00:00:00" WorkDayStartTime="00:00:00"
                                                        AllowDelete="False"
                                                        NumberOfHoveredRows="1" SelectedDate="2012-06-10"
                                                        EnableExactTimeRendering="True" Height="460px"
                                                        EnableEmbeddedSkins="False" Skin="Macys"
                                                        onclientappointmentcontextmenu="hideActiveToolTip"
                                                        onclientappointmentdoubleclick="hideActiveToolTip"
                                                        onclientrecurrenceactiondialogshowing="hideActiveToolTip"
                                                            OverflowBehavior="Expand">
                                                        <AdvancedForm Width="60%" Modal="True" />
                                                        <ResourceTypes>
                                                        <telerik:ResourceType DataSourceID="SqlDataSource2" ForeignKeyField="USERID"
                                                        KeyField="ID" Name="Users" TextField="USERNAME" />
                                                        </ResourceTypes>
                                                        <TimelineView UserSelectable="False" />
                                                        <WeekView DayEndTime="23:59:59" ColumnHeaderDateFormat="dddd, d"
                                                            GroupingDirection="Vertical" />
                                                        <Localization AdvancedEditAppointment="Edit" AdvancedNewAppointment="New"
                                                            AllDay="Range" />
                                                        <MonthView FirstDayHeaderDateFormat="MMMM dd" ColumnHeaderDateFormat="MMMM dddd"
                                                            HeaderDateFormat="MMMM, yyyy" />
                                                    </telerik:RadScheduler>
                                                   
                                                    <div align="center">                                                   
                                                        <asp:ImageButton ID="btnSubmit" runat="server"
                                                            ImageUrl="../images/b_submit_sm.gif" onclick="btnSubmit_Click" />
                                                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                                        <asp:ImageButton ID="btnCancel" runat="server"
                                                            ImageUrl="../images/b_cancel.gif" onclick="btnSubmit_Click" />
                                                        &nbsp;&nbsp;&nbsp;&nbsp;
                                                        </div>
                                                       
                                                        &nbsp;<asp:SqlDataSource
                                                       
                                                        ID="SqlDataSource1" runat="server"
                                                        ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
                                                        DeleteCommand="DELETE FROM &quot;AVAILABILITY_TEST&quot; WHERE &quot;ID&quot; = :ID"
                                                        InsertCommand="INSERT INTO &quot;AVAILABILITY_TEST&quot; (&quot;ID&quot;, &quot;SUBJECT&quot;, &quot;START_TIME&quot;, &quot;END_TIME&quot;, &quot;USERID&quot;, &quot;RECURRENCERULE&quot;, &quot;RECURRENCEPARENTID&quot;) VALUES (:ID, :SUBJECT, :START_TIME, :END_TIME, :USERID, :RECURRENCERULE, :RECURRENCEPARENTID)"
                                                        ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
                                                        SelectCommand="SELECT * FROM &quot;AVAILABILITY_TEST&quot;"
                                                        UpdateCommand="UPDATE &quot;AVAILABILITY_TEST&quot; SET &quot;SUBJECT&quot; = :SUBJECT, &quot;START_TIME&quot; = :START_TIME, &quot;END_TIME&quot; = :END_TIME, &quot;USERID&quot; = :USERID, &quot;RECURRENCERULE&quot; = :RECURRENCERULE, &quot;RECURRENCEPARENTID&quot; = :RECURRENCEPARENTID WHERE &quot;ID&quot; = :ID">
                                                        <DeleteParameters>
                                                            <asp:Parameter Name="ID" Type="Decimal" />
                                                        </DeleteParameters>
                                                        <InsertParameters>
                                                            <asp:Parameter Name="ID" Type="Decimal" />
                                                            <asp:Parameter Name="SUBJECT" Type="String" />
                                                            <asp:Parameter Name="START_TIME" Type="DateTime" />
                                                            <asp:Parameter Name="END_TIME" Type="DateTime" />
                                                            <asp:Parameter Name="USERID" Type="Decimal" />
                                                            <asp:Parameter Name="RECURRENCERULE" Type="String" />
                                                            <asp:Parameter Name="RECURRENCEPARENTID" Type="Decimal" />
                                                        </InsertParameters>
                                                        <UpdateParameters>
                                                            <asp:Parameter Name="SUBJECT" Type="String" />
                                                            <asp:Parameter Name="START_TIME" Type="DateTime" />
                                                            <asp:Parameter Name="END_TIME" Type="DateTime" />
                                                            <asp:Parameter Name="USERID" Type="Decimal" />
                                                            <asp:Parameter Name="RECURRENCERULE" Type="String" />
                                                            <asp:Parameter Name="RECURRENCEPARENTID" Type="Decimal" />
                                                            <asp:Parameter Name="ID" Type="Decimal" />
                                                        </UpdateParameters>
                                                    </asp:SqlDataSource><asp:SqlDataSource
                                                        ID="SqlDataSource2" runat="server"
                                                        ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
                                                        ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
                                                        SelectCommand="SELECT &quot;ID&quot;, &quot;USERNAME&quot; FROM &quot;AVAILABILITY_TEST_USERS&quot;">
                                                    </asp:SqlDataSource>
                                                   
                    
                                                    <telerik:RadToolTipManager runat="server" ID="RadToolTipManager1" Width="130"
                                                            Height="40" Skin = ""
                                                            OnAjaxUpdate="RadToolTipManager1_AjaxUpdate" />
                                                    <div style="display: none;">
                                                        <div id="contentContainer">
                                                        <%--
                                                            Starts on: <span id="startTime"></span>
                                                            <br />
                                                            Ends on: <span id="endTime"></span>
                                                            <hr />
                   
                                                            Description:
                                                        --%>
                                                            <div id="descriptionDiv">
                                                            </div>
                                                        </div>
                                                    </div>
                                                    </telerik:RadAjaxPanel>
                                                  </td>
                                            </tr>
                                           
                                        </tbody>
                                    </table>
    
    <!-- Permanent availability -->
                       
                                </div>
                            </td>
                        </tr>
                    </table>
  <!-- End Workspace -->    
 
</asp:Content>

 

 

 

Plamen
Telerik team
 answered on 13 Jul 2012
5 answers
414 views
I having Treeview with several nodes and sub nodes
The user must have the option to sort the treeview items,using context menu items Like MoveUp,MoveDown
Is their any methods available for moving the node up and down in the RadTreeview using clientside functions
like movenodeup,movenodedown etc,
Please let me know as  soon as possible,
this is very very urgent task.
thanks in advance.


Marbry
Top achievements
Rank 1
 answered on 13 Jul 2012
1 answer
91 views
Hello,
There is an ability in in Hyperlink Manager to enter anchor name with spaces, etc. No validation performed.
Could you please reply if it can be fixed?
Rumen
Telerik team
 answered on 13 Jul 2012
4 answers
268 views
I have a simple question.  How can I ajaxify the ContentPlaceHolder in a MasterPage?  I currently have a Master Page with 2 ContentPlaceHolders.  I also have a RadMenu and want to ajaxify the menu selections so that it refreshes the ContentPlaceHolders with the appropriate content page updates.  I read on the forums that I need to wrap the ContentPlaceHolder in a regular Panel for this scenario to work, but it is still not working.

Is this possible and if so how?

Thanks in advance!
Martin Roussel
Top achievements
Rank 1
 answered on 13 Jul 2012
3 answers
321 views
Hi Everyone,

I have a RadEditor with couple of toolbar buttons which includes hyperlink manager toolbar button.

I have edit modes as design, html and preview.

I would like to disable hyperlink when on html and preview modes, and disable on design mode until a button is clicked.

i tried if mode = design, visible = false, but it does not work all the time.

Example:
1st time when I load the module, by default it is in design mode, and hyperlink is disabled, when i switch to html/preview modes, the hyperlink is disabled,but when i switch back again to design ,the hyperlink is enabled.

"Any Idea how to disable hyperlink in all the 3 modes and enable only on design mode when a button is clicked."

Thanks in advance for you help on this.

-Rad
Vessy
Telerik team
 answered on 13 Jul 2012
1 answer
111 views
Hello,
Similar to this the HTML entity characters (like > or < ) are not escaped on Hyperlink Manager fields.
If they appear in email Subject field they break the markup with something like "originalAttribute=".
Could you please comment if it can be resolved?
Rumen
Telerik team
 answered on 13 Jul 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?