Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
152 views
Is there a limit on the number of resources that I can show when using the Scheduler?  Also, can I specify the width of the resources column manually?
Peter
Telerik team
 answered on 14 May 2008
2 answers
156 views
I've been struggling a bit with the RadAjaxManager.  I have it working okay and updating Panel2 from clicking on a RadTreeView Node on Panel1 but the Loading graphic will not dissapear even after panel2 is loaded.  Any ideas?

<%@ Page Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false" CodeFile="Pages.aspx.vb" Inherits="Pages" title="Untitled Page" %> 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">  
    &nbsp;  
<script type="text/javascript">  
                    //<![CDATA[
                        function confirmCallBackFn(arg)
                        {
                            alert("Confirm returned the following result: " + arg);
                             eventArgs.set_cancel(true);
                        }
                        
                        function promptCallBackFn(arg)
                        {
                            alert ("Prompt returned the following result: " + arg);
                        }
                        function onClientContextMenuItemClicked(sender, args)
                         {
                         if (!confirm("Are you sure you want to delete this item?")) {
                            args.set_cancel(true);
                         }
                            
                           // radconfirm('Are you sure?', confirmCallBackFn); 
                            //args.set_cancel(true);
                             //var node = eventArgs.get_node();   
                            //var item = eventArgs.get_menuItem();
  
                            // if ((item.get_text() == "Network Search") && (node.get_text() == "Printers"))
                            //  {       
                             //     eventArgs.set_cancel(true);
                              //}
                         }
                        //]]>                                                                          
                        </script> 
 
<table cellpadding="10" cellspacing="0" border="0">  
<tr><td valign="top">  
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">  
        <AjaxSettings> 
            <telerik:AjaxSetting AjaxControlID="RadTreeView1">  
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="panel2" LoadingPanelID="RadAjaxLoadingPanel1" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
        </AjaxSettings> 
    </telerik:RadAjaxManager> 
    <asp:Panel ID="panel1" runat=server>  
   
    <telerik:RadTreeView ID="RadTreeView1" runat="server" Skin="Hay" AllowNodeEditing="True" EnableDragAndDrop="True" EnableDragAndDropBetweenNodes="True" MultipleSelect="false" OnNodeDrop="RadTreeView1_HandleDrop" OnContextMenuItemClick="RadTreeView1_ContextMenuItemClick" BorderStyle="Dotted" BorderWidth="1" OnClientContextMenuItemClicking="onClientContextMenuItemClicked">  
        <CollapseAnimation Duration="100" Type="OutQuint" /> 
        <ExpandAnimation Duration="100" /> 
        <ContextMenus> 
                                <telerik:RadTreeViewContextMenu Skin="Hay" ID="MainContextMenu" runat="server" > 
                                    <Items> 
                                        <telerik:RadMenuItem Value="NewMenuItem" Text="New Menu Item" ImageUrl="~/images/AddRecord.gif"></telerik:RadMenuItem> 
                                        <telerik:RadMenuItem Value="DeleteMenuItem" Text="Delete Menu Item" ImageUrl="~/images/Delete.gif"></telerik:RadMenuItem> 
                                    </Items> 
                                </telerik:RadTreeViewContextMenu> 
                            </ContextMenus> 
 
    </telerik:RadTreeView> 
 </asp:Panel> 
 </td><td>  
    <asp:Panel ID="panel2" runat=server>  
         
        <asp:Label ID="mylabel" text="no value" runat=server></asp:Label> 
        <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="75px" 
            Width="75px">  
            <img alt="Loading..." src="images/loading6.gif" style="border-right: 0px; border-top: 0px;  
                border-left: 0px; border-bottom: 0px" /> 
        </telerik:RadAjaxLoadingPanel> 
        &nbsp;  
        <telerik:RadTabStrip ID="RadTabStrip2" runat="server" MultiPageID="RadMultiPage1" Skin="Hay" SelectedIndex="0">  
            <Tabs> 
                <telerik:RadTab runat="server" Text="Page Editor" Selected="True">  
                </telerik:RadTab> 
                <telerik:RadTab runat="server" Text="Menu Properties">  
                </telerik:RadTab> 
            </Tabs> 
        </telerik:RadTabStrip> 
        <telerik:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0">  
            &nbsp;<telerik:RadPageView ID="RadPageView1" runat="server" Width="300">  
                <telerik:RadEditor ID="RadEditor1" runat="server" Skin="Hay">  
                    <Content> 
</Content> 
                </telerik:RadEditor> 
            </telerik:RadPageView>      
            <telerik:RadPageView ID="RadPageView2" runat="server" Width="300">  
                <table width="680" border="0">  
                <tr><td>&nbsp;</td></tr>  
                </table> 
                <telerik:RadFormDecorator ID="RadFormDecorator1" runat="server" Skin="Web20" /> 
                <asp:Label ID="Label2" runat="server" Text="Visible:"></asp:Label><asp:RadioButton ID="RadioButton3" runat="server" Text="Yes" GroupName="visible" Checked="true" /><asp:RadioButton ID="RadioButton4" runat="server" Text="No" GroupName="newwindow" /> 
                <table cellpadding="5" cellspacing="0" border="0" class="dottedBorder">  
                    <tr> 
                        <td colspan="2" align=center><strong>Linking Options</strong></td>  
                    </tr> 
                    <tr> 
                        <td> 
                            <asp:RadioButton ID="linktype1" runat="server" Text="No Link" GroupName="linktype" /> 
                        </td> 
                        <td> 
                            &nbsp;  
                        </td> 
                    </tr> 
                     <tr> 
                        <td> 
                            <asp:RadioButton ID="linktype2" runat="server" Text="Page Link" GroupName="linktype" /> 
                        </td> 
                        <td> 
                            <telerik:RadComboBox ID="RadComboBox1" runat="server" Skin="Hay">  
                            </telerik:RadComboBox> 
                        </td> 
                    </tr> 
                    <tr> 
                        <td> 
                            <asp:RadioButton ID="linktype3" runat="server" Text="Page Link" GroupName="linktype" /> 
                        </td> 
                        <td> 
                            <telerik:RadComboBox ID="RadComboBox2" runat="server" Skin="Hay">  
                            </telerik:RadComboBox> 
                        </td> 
                    </tr> 
                    <tr> 
                        <td> 
                            <asp:RadioButton ID="linktype4" runat="server" Text="External Link" GroupName="linktype" /> 
                        </td> 
                        <td> 
                            <telerik:RadTextBox ID="RadTextBox1" runat="server" Text="http://" Skin="Hay">  
                            </telerik:RadTextBox> 
                        </td> 
                    </tr> 
                    <tr> 
                        <td colspan="2">  
                            <asp:Label ID="Label1" runat="server" Text="Open in new window:"></asp:Label><asp:RadioButton ID="RadioButton1" runat="server" Text="Yes" GroupName="newwindow" /><asp:RadioButton ID="RadioButton2" runat="server" Text="No" GroupName="newwindow" Checked=true /> 
                        </td> 
                    </tr> 
                    <tr> 
                        <td colspan="2" align=center><asp:Button ID="Button1" runat="server" Text="Submit" /></td>  
                    </tr> 
                </table> 
            </telerik:RadPageView>      
        </telerik:RadMultiPage> 
        &nbsp;&nbsp;  
   </asp:Panel> 
  </td></tr></table> 
    &nbsp;  
      
          
</asp:Content> 
 
   
Derek
Top achievements
Rank 1
 answered on 14 May 2008
1 answer
231 views
Hi

I have a scenario where a tab's style can be set to none in C#. E.g.

    Tab1.Style.Add(HtmlTextWriterStyle.Display, "none");

This works nicely and as expected. This 'Tab1' has a value of 'tabDocuments'.

However how do I show this again in Javascript? I tried the following...

$find(gRadTabStrip1ID).findTabByValue('tabDocuments').get_element().style.display = '';


... however I must be using a wrong approach?


Kind regards

Mark Eaton
Paul
Telerik team
 answered on 14 May 2008
2 answers
200 views
My company uses Radcontrols and I'm working on a project related to RadScheduler. My task is explained below:
Notifications have to be sent to the people associated to the recurring event/appointment. My sql retrieves all information like Start date, End Date, RecurrenceRule, ...etc, Along with that it also retrieves all the users with their email id's to send reminders of the events to be held .
  Using  RadScheduler RadScheduler1 = new RadScheduler();

I could retrieve the first half of my information(Start date, End Date, RecurrenceRule, ...etc). Now using the following statements I tried to retrieve the extra information related to the user but I'm getting the count as 0.
   The code I used is as follows:

dtRecurrence is the datatable that stores the values returned from the following sql statement
SELECT ID , Subject, Start , [End] , RecurrenceRule , RecurrenceParentID, usrID , usrEmail  FROM tblEvents";
RadScheduler RadScheduler1 = new RadScheduler();
RadScheduler1.DataKeyField = "ID";
RadScheduler1.DataStartField =
"Start";
RadScheduler1.DataEndField =
"End";
RadScheduler1.DataSubjectField =
"Subject";
RadScheduler1.DataRecurrenceField =
"RecurrenceRule";
RadScheduler1.DataRecurrenceParentKeyField =
"RecurrenceParentID";
RadScheduler1.DataSource = dtRecurrence;

ResourceType

resourceType = new ResourceType("User");
resourceType.TextField =
"usrEmail";
resourceType.KeyField = "ID";
resourceType.ForeignKeyField = "usrID";
resourceType.DataSource = dtRecurrence;

RadScheduler1.ResourceTypes.Add(resourceType);
RadScheduler1.DataBind();

Now when i tried to output the values of the user, I got an error

foreach

(Appointment recurringapt in RadScheduler1.Appointments)
{
        Response.Write("Resource Text is : " + recurringapt.Resources[0].Text);

        Response.Write("Resource Text is : " + recurringapt.Resources[0].Key);

}

So I did a count on the Resources and it gave me a count of 0. So my question to you is: I'm doing something wrong here. If so do let me know the correct code to go about this

sherley
Top achievements
Rank 1
 answered on 14 May 2008
1 answer
158 views
If I use predefined skin, how to use my original font size and color without using  "EnableEmbeddedSkins=false" and change css file.
Georgi Tunev
Telerik team
 answered on 14 May 2008
1 answer
277 views
hiya,

I have a "refresh" button in the grid that refreshes the grid:

<asp:LinkButton ID="lnkRefresh" runat="server" CausesValidation="false" CommandName="RebindGrid"
                                    Visible="true"><img style="border:0px" alt="" src="DataEditing/img/Refresh.gif" /> Refresh</asp:LinkButton>

What I need it to do is refresh the entire page, ie, the controls that are OUTSIDE the grid.

I this possible?

many thanks,

yogi
Steve
Telerik team
 answered on 14 May 2008
4 answers
144 views
The new controls in 2008 Q1 are great!  One idea for the future would be an audio control.  Currently, I cannot find any good audio control components out there for asp.net. 

It's actually fairly easy to embed sounds in a site, but not in a cross-browser way.  That, and some methods steal focus when the sounds play.  Would be nice to have this included with the library.  MP3 support would be icing on the cake....
Shaun Peet
Top achievements
Rank 2
 answered on 14 May 2008
6 answers
286 views
hiya,

We have an older version of the controls, but want to repeat the functionality that's on this page:

http://www.telerik.com/DEMOS/ASPNET/Prometheus/Calendar/Examples/DatePicker/ClientAPI/DefaultCS.aspx

I can see the follwoing call to a javascript function:

 var datePicker = $find("<%= RadDatePicker1.ClientID %>");

where is the "find" function?
Ideally, I'd like to be able to download this separately.Is it possible?

If not, where would I find it in the download?

many thanks,

yogi
Chris Yoker
Top achievements
Rank 1
 answered on 14 May 2008
1 answer
79 views

Using the ASP.NET grid, I had a page that persisted client-side selection, using this example:

http://www.telerik.com/community/code-library/submission/b311D-khchg.aspx

After upgrading to the AJAX control, this page now errors, due to Javascript choking on:

function

GridCreated(){
grid =
this;
var pageIndex = grid.CurrentPageIndex.toString();

...specifically, "grid.currentPageIndex is null or not an object".

Suggestions?

Bill

Yavor
Telerik team
 answered on 14 May 2008
13 answers
609 views

I have a radtreeview inside radcombobox. My treeview is populated on demand. This combobox resides inside formview which is by default in edit mode. And i have an objectdatsource that contains the select and update mode.

The problem with my update mode is, the selected value of combox always becomes 0 it doesn't change even when using combo.set_value("something");
In client side the value changes but not in server side even when trackChanges() and commitChanges() is applied.

The following link contains the type of solution but its not working, with my q1 2008 415 version. it has a special parameter called <telerik:AjaxComboValueParameter />. Wouldn't it be better if that parameter would be provided by Telerik instead of trying to code it.
http://www.telerik.com/community/code-library/submission/b311D-ttdgm.aspx

Following is my javascript file for setting the value of the combobox when selecting a treenode. My objectdatasource update parameter contains <asp:ControlParameter Name="parentId" Type="Int32" ControlID="cbo" PropertyName="SelectedValue" />. The name of my radcombox inside formview edit mode is cbo and treeview is radPortalsTree.

function
radTreeViewPortalParent_OnClientNodeClicking(sender,eventArgs)

{

var comboBox=$find('<%=FormViewPortal.FindControl("cbo").ClientID%>');

var node=eventArgs.get_node();

var portalTree=$find('<%= radPortalsTree.ClientID %>');

if(portalTree.get_selectedNode().get_value()!=node.get_value())

{

comboBox.trackChanges();

comboBox.set_text(node.get_text());

comboBox.set_value(node.get_value());

var cboItem=comboBox.get_items().getItem(0);

cboItem.set_value(node.get_value());

comboBox.commitChanges();

}

comboBox.hideDropDown();

}

Veselin Vasilev
Telerik team
 answered on 14 May 2008
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?